assigning letters to unknown # of entries

almagg

Well-known Member
Joined
Aug 21, 2002
Messages
705
i have this list and the values that start with "NT" do not get counted.
and this is what they wanted originally and i had on the report.
now they want another column with letters assigned to all of the entries.
how would i deal with these letters? i am assuming it will involve ASCI characters but i never know how long the list will be and could possibly go into double letters(though it would not be monstrously long - the longest i see so far goes up to "U")


A_______NT#####
B___1___B####
C___2___A####
D_______NT#####
E___3___B####

thanks.
 

Excel Facts

Last used cell?
Press Ctrl+End to move to what Excel thinks is the last used cell.
Don't know what you want really.
If you just want to get the first letter into another column something like

=LEFT(A1,1)
 
Upvote 0
maybe try (note: only works up to "IV" (that's only 256 rows). hopefully your list isn't that long):

=IF(ROW(A1)<=26,LEFT(ADDRESS(1,ROW(A1),4),1),LEFT(ADDRESS(1,ROW(A1),4),2))
 
Last edited:
Upvote 0
here's another one which goes to "ZZ" (which equates to 754 rows of data):

Code:
=IF(ROW(A1)<=26,LOOKUP(ROW(A1),{1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26;"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"}),LOOKUP(IF(ROUND((ROW(A1)/26-ROUNDDOWN(ROW(A1)/26,0))*26,0)=0,ROUNDDOWN(ROW(A1)/26,0)-1,ROUNDDOWN(ROW(A1)/26,0)),{1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26;"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"})&LOOKUP(IF(ROUND((ROW(A1)/26-ROUNDDOWN(ROW(A1)/26,0))*26,0)=0,26,ROUND((ROW(A1)/26-ROUNDDOWN(ROW(A1)/26,0))*26,0)),{1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26;"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"}))
 
Upvote 0

Forum statistics

Threads
1,214,875
Messages
6,122,047
Members
449,064
Latest member
scottdog129

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