View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default AUTOMATICALLY NAME A FIELD WITH THE TAB NAME in excel

That is NOT exactly what you were looking for and can give an erroneous
result.

You must use a cell reference in the formula like so

=RIGHT(CELL("filename",A1),(LEN(CELL("filename",A1 ))-FIND("]",CELL("filename",A1))))

If you omit a cell reference the results will be incorrect if you switch to
another sheet, calculate then switch back to original sheet.

Easy enough to experiment with the two formulas to see the results.


Gord Dibben MS Excel MVP


On Wed, 8 Jul 2009 10:49:01 -0700, JamesI
wrote:

This is exactly what I was looking for. Thank you.
JamesI


"John Bundy" wrote:

After saving the workbook

=RIGHT(CELL("filename"),(LEN(CELL("filename"))-FIND("]",CELL("filename"))))
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"jygong" wrote:

How would I have the name of the spreadsheet tab (on the bottom) to
automatically appear in a cell field on the spreadsheet?