How to find the last right hand numbers

texasalynn

Well-known Member
Joined
May 19, 2002
Messages
8,458
I am trying to figure on a formula to return the right x digits from a cell. The problem is that sometimes it will be the last 3 and sometimes the last 4. My data looks like this
01002BI732
01002BJ735
01002BK906
01002BP1101
01002BQ1116
01002BR1118
01002BW705
01002BY1325
So what I need is the numbers after the alpha. Does someone know how I can do this?

Thanks . . . texasalynn
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
If your leading characters always number 7 as in your example, you could use Data-->Text to Columns-->Fixed Width & create a break line after the last alpha character.

HTH,

Smitty
 
Upvote 0
This will work as well

=IF(ISNUMBER(VALUE(MID(A1,LEN(A1)-3,1))),RIGHT(A1,4),RIGHT(A1,3))

This formula checks to see if the 4 character back is a number and uses that to determine where to do the right string to.
 
Upvote 0
Well of course Aladin! I was over thinking it. Yours would be the simple answer and works.

Thanks . . . texasalynn
 
Upvote 0

Forum statistics

Threads
1,222,170
Messages
6,164,377
Members
451,886
Latest member
elpepe1970

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