On other hand, Excel does not have any function which will provide column letter as a result. Therefore. someone needs to write complex formulas to get column letter as a output. And writing complex formula in excel is quite time consuming task. which results into slowdown of excel calculation task and make excel heavy. As a result excel take more time to open the file.

Hence to make this task simple, I have a user defined function which will return column letter just providing column number as a input parameter.

Here is the function which will make your task easy and save time to create complex formulas to get column letter:

Function Column_Letter(ColumnNumber As Long) As String

' Author: Dreams24

' Written for VBA Tricks and tips blog

' https://www.vbatricksntips.com

If ColumnNumber < 26 Then

' Columns A-Z

ColumnLetter = Chr(ColumnNumber + 64)

ElseIf ColumnNumber > 26 And ColumnNumber <= 702 Then

' Columns AA-ZZ

ColumnLetter = Chr(Int((ColumnNumber - 1) / 26) + 64) & Chr(((ColumnNumber - 1) Mod 26) + 65)

Else

' Columns AAA-XFD

Column-Letter=Left(Cells(1,ColumnNumber).Address(1,0),InStr(1,Cells(1,ColumnNumber).Address(1, 0), "$") - 1)

End If

End Function

Function Column_Letter(ColumnNumber As Long) As String

' Author: Dreams24

' Written for VBA Tricks and tips blog

' https://www.vbatricksntips.com

If ColumnNumber < 26 Then

' Columns A-Z

ColumnLetter = Chr(ColumnNumber + 64)

ElseIf ColumnNumber > 26 And ColumnNumber <= 702 Then

' Columns AA-ZZ

ColumnLetter = Chr(Int((ColumnNumber - 1) / 26) + 64) & Chr(((ColumnNumber - 1) Mod 26) + 65)

Else

' Columns AAA-XFD

Column-Letter=Left(Cells(1,ColumnNumber).Address(1,0),InStr(1,Cells(1,ColumnNumber).Address(1, 0), "$") - 1)

End If

End Function