Pages

Friday, April 5, 2013

UDF to extract Column Name

If you want to extract the column name from a range. Try this UDF



Function colname(rng As Range) As String
    Dim arr As Variant
    arr = Split(rng.Address, "$")
    colname = arr(1)
End Function

No comments:

Post a Comment