What is the function to get the current line number and the current column name for a cell in Excel?
You can use the For example, if you enter If you want the column letter, you can use the Regardless, if you should still want to get the column letter, you can simply add 64 to the column number (64 being one character less then Just an FYI, I got 64 from an ASCII table. You could also use the However, this will not work with twoletter columns. In that case, you need the following formula to properly parse twoletter columns:
I'm not sure if there is an easier way to do it or not, but I know that works from cell 


Try the following function:



Try this
This gives you exact column header, without any $ etc. 


Type this into any cell: Español:
English:
You can replace column() by row number. 


Slightly manual but less VBA and a simpler formula:
Once values are copied, find and replace 


This will work as well



Another possible way would be to use something like this:
Where So if you were to copy the above string to cell A1 of 'MySheet2', it would evaluate as This would enable you, for example, to use 


To get column name I used the following formulae. For a particular cell:
For the current cell:
Try this variation. It works on 3letter columns, and doesn't leave a "$" on the front end:



The address formula works by returning the column and row name. The returned format will always be If we know that $ will always occur at the first character, we can use the first mid formula to start pulling characters after the first $ sign (i.e. the 2nd character). Then, we find the next $ sign (as we know there will only be two) and we know how many characters there are between the first and the second dollar sign. The rest is simple subtraction. 


Solution for polish Excel version:



Here's a VBA, user defined formula, solution. It works with 1, 2, & 3 letter columns. Put the following in a code module:
=COLUMNLETTER() in any cell will return the column letter of the cell. This User Defined Function works great when creating generic formulas inside the INDIRECT function. 


Here's how you can find the column heading (i.e. the letter):



try this:



The following formula works no matter where you put it (it will give you back the column name).



try this:
this function effective until "ZY1" or column=701 





protected by Mokubai♦ Sep 17 '14 at 11:38
Thank you for your interest in this question.
Because it has attracted lowquality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site.
Would you like to answer one of these unanswered questions instead?
LIN
andCOL
but the problem is they return numbers, and I need the column letter toINDIRECT
it. – Jader Dias Jul 28 '11 at 14:36OFFSET
function in conjunction with, or instead of, theINDIRECT
formula in that case. If you want to use strings, though, I also updated my answer. – Breakthrough Jul 28 '11 at 14:39