views:

262

answers:

2

I could not find the function that returns the name of the cell referenced. For example, =SOMETHING(A5) that will return A5 as string.

So that, I can write ="For more information, see " & SOMETHING(F50) & "." in a cell and the cell will read For more information, see F50., and then, when I move the F50 cell, the text will also change.

So, what is that SOMETHING?

If it works for Google Spreadsheet it's the best, but if you are not familiar with Google Spreadsheet, OpenOffice Calc and MS Excel solutions are most probably compatible too.

+2  A: 

In Excel you can use the ADDRESS function.

dawntrader
Mark Rushakoff
Thanks! I tried that, =ADDRESS( ROW(F50), COLUMN(F50), 4 ) returns what I want :)The bad thing is I need to write the cell reference twice. Any better way?
yuku
+1  A: 

In Excel you can also use the CELL function.

="For more information, see " & CELL("address",F50) & "."

will return

For more information, see $F$50.


An alternate is to create a hyperlink to the location based on the CELL function. It will be easier for the end user, but the formula is more complex.

=HYPERLINK((MID(CELL("filename",F50),4,255)&"!"&CELL("address",F50)),"For more information click here.")

this will return

For more information click here.

and when it is clicked on, the cell specified will be selected.

Robert Mearns