Make a cell show the name of the sheet tab

L

LPatt

Is there a formula to make cell A5 show the name of the tab for that sheet
automatically?

Thank you for any help
 
B

Biff

Try this:

=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,255)

The file must already exist. In other words, it must have already been saved
and given a name.

Biff
 
L

LPatt

Thank you it worked perfectly!!

Biff said:
Try this:

=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,255)

The file must already exist. In other words, it must have already been saved
and given a name.

Biff

LPatt said:
Is there a formula to make cell A5 show the name of the tab for that sheet
automatically?

Thank you for any help
 
P

paul

more than one way to skin a cat
=RIGHT(CELL("filename",IV1),LEN(CELL("filename",IV1))-FIND("]",CELL("filename",IV1),1))
the cell eference IV1 can be any cell reference,it seems to work without a
cell reference but things start to go wrong if you copy tht sheet or workbook.
It anchors that formula to that sheet.
 
B

Biff

You're welcome. Thanks for the feedback!

Biff

LPatt said:
Thank you it worked perfectly!!

Biff said:
Try this:

=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,255)

The file must already exist. In other words, it must have already been
saved
and given a name.

Biff

LPatt said:
Is there a formula to make cell A5 show the name of the tab for that
sheet
automatically?

Thank you for any help
 
D

Dave Peterson

If you leave off the range reference, the formula will return info from the
sheet that was active when excel recalculated.

Open two workbooks (each must have been saved)
put this in A1 of the first worksheet of each workbook:
=cell("Filename")

put this in A2 of the first worksheet of each workbook:
=cell("filename",a1)

and then window|arrange|horizontal
so you can see both worksheets

And force a couple of recalculations (Hit F9).
then select the other worksheet and hit F9.

Notice the difference.


Select one
more than one way to skin a cat
=RIGHT(CELL("filename",IV1),LEN(CELL("filename",IV1))-FIND("]",CELL("filename",IV1),1))
the cell eference IV1 can be any cell reference,it seems to work without a
cell reference but things start to go wrong if you copy tht sheet or workbook.
It anchors that formula to that sheet.
--
paul
[email protected]
remove nospam for email addy!

LPatt said:
Is there a formula to make cell A5 show the name of the tab for that sheet
automatically?

Thank you for any help
 
Top