Single Formula

Jesan

New Member
Joined
Mar 16, 2016
Messages
11
Hello,

I would like to ask if there is a single formula wherein I change the value of "A" to "B" to "C" and "D" for the ff. I try the SUBSTITUTE but I do it one by one.

KIT-1234567-01-A
KIT-1234567-01-B
KIT-1234567-01-C
KIT-1234567-01-D


Thank you so much,
San
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
Assuming that was a real example and not a simplification, try this:
If your data doesn't start in A1 you will need to change the reference.

Excel Formula:
=SUBSTITUTE(A1,"-"&RIGHT(A1,1),"-"&CHAR(CODE(RIGHT(A1,1))+1))
 
Upvote 0
Solution
Another possibility: (Where you subtract 6 in this example, because that's the row number that the lettering starts.)

Cell Formulas
RangeFormula
A6:A21A6=CONCATENATE("KIT-1234567-01-",SUBSTITUTE(SUBSTITUTE(ADDRESS(1,ROW()-6+1),"$",""),"1",""))


And I'm not sure if you want it to count up to AA after Z or go back to A after you get to Z or if you just want it to increment up a letter for just those 4 values. But if you want it to go back to A after it gets to Z (be in a continous loop), then:
Cell Formulas
RangeFormula
A1:A29A1=CONCATENATE("KIT-1234567-01-",MID(IFERROR(ADDRESS(1,MOD(ROW(),26)),"$Z"),2,1))
 
Upvote 0

Forum statistics

Threads
1,214,822
Messages
6,121,772
Members
449,049
Latest member
greyangel23

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