...for eg.. if the col no is 26 then this function would return "Z" as column name
Function Convert_Column()
Dim MyColumn As String, Here As String
' Get the address of the active cell in the current selection
Here = ActiveCell.Address
' Because .Address is $
' character and the characters after the column letter(s).
Convert_Column = Mid(Here, InStr(Here, "$") + 1, InStr(2, Here, "$") - 2)
End Function
No comments:
Post a Comment