View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
danpt danpt is offline
external usenet poster
 
Posts: 49
Default Alpha to Numeral column name

I need a macro or function to translate alphabetic column name to numeral
column number like:
Sub alphatonumeral()
Dim alpha, numeral As Variant
alpha = UCase(InputBox(prompt:="What is the alphabetic column name?"))
' translation body will be similar to formula "=column(BA:BA)" if input
alpha is BA
numeral = 53 ' for BA
MsgBox numeral
End Sub