Formula for PLACES not displaying the "TH" Places like 45th Place it comes out 45 Place

RudeBoy

Active Member
Joined
Feb 2, 2003
Messages
431
Office Version
  1. 365
Platform
  1. Windows
In excel I have a formula displaying places
ie !st Place, 2nd Place 3rd Place etc

The formula is like this:
=D46&MID("thstndrdth",MIN(100,2*RIGHT(D46)*(MOD(D46-11,100)>2)+1),2)&" Place"

The problem I am encountering is that the "TH" places are not displaying like this:
45 Place
46 Place
47 Place
48 Place
49 Place
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
In excel I have a formula displaying places
ie !st Place, 2nd Place 3rd Place etc

The formula is like this:
=D46&MID("thstndrdth",MIN(100,2*RIGHT(D46)*(MOD(D46-11,100)>2)+1),2)&" Place"

The problem I am encountering is that the "TH" places are not displaying like this:
45 Place
46 Place
47 Place
48 Place
49 Place
That method for finding the ordinal suffix does not look right to me (I use 9 in place of that first 100). Try it like this...

=D46&MID("thstndrdth",MIN(9,2*RIGHT(D46)*(MOD(D46-11,100)>2)+1),2)&" Place"
 
Upvote 0
That method for finding the ordinal suffix does not look right to me (I use 9 in place of that first 100). Try it like this...

=D46&MID("thstndrdth",MIN(9,2*RIGHT(D46)*(MOD(D46-11,100)>2)+1),2)&" Place"

That Worked Thanks..

Only fall out is st has a space in front
So every st place has a space like this EXCEPT 1st.

1st is fine then 21 st, 31 st all have spaces but that is no big deal :-) Thanks
 
Upvote 0
That Worked Thanks..

Only fall out is st has a space in front
So every st place has a space like this EXCEPT 1st.

1st is fine then 21 st, 31 st all have spaces but that is no big deal :-) Thanks
:confused: The formula I posted, as I posted it, has no space between the number and the ordinal suffix for any number in cell D46. Did you modify the formula I posted? If so, show us what you are now using.
 
Last edited:
Upvote 0
:confused: The formula I posted, as I posted it, has no space between the number and the ordinal suffix for any number in cell D46. Did you modify the formula I posted? If so, show us what you are now using.

=D27&MID("thstndrdth",MIN(9,2*RIGHT(D27)*(MOD(D27-11,100)>2)+1),2)&" Place"

Here is the code but maybe it just looks like a space
as that font is big. I did a copy & paste in notepad & I do not see a space so its just the font so we are good thanks :-)
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,289
Members
452,631
Latest member
a_potato

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top