Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel 2003 VBA - Convert Letter to a number 1

Status
Not open for further replies.

BillB66

Technical User
Apr 24, 2008
63
AU
I am trying to convert a Single character into a number
eg A=1 , B =2 etc in Excel 2003 Vba
can anyone supply some simple code ?

 
Why are you wanting to do this exactly? Often, such a question goes toward an action that can be simplified other ways.

Cheers, Glenn.

Beauty is in the eye of the beerholder.
 
...and if you want a VBA response ,please post in the VBA forum: Forum707

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
... and if you don't need VBA, you can of course do this with the "code" function
=CODE(A1)-CODE("a")+1
 




Of course, you can also do...
[tt]
=COLUMN(A1)
[/tt]
and get the same result.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top