Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Insert Excel wooksheet name in cell 1

Status
Not open for further replies.

jnix

MIS
Feb 18, 2002
101
US
How can I get excel to insert the worksheet name in a cell on the worksheet?thanks,
jnxi
 
Hi!

You could try something like:

[tt]=CELL("FILENAME",F10)[/tt]

"Stolen from" xlbo's excellent faq faq68-2561

HTH Roy-Vidar
 
Of course I stole and pasted the wrong formula, sorry. Previous one displays complete path, this one should provide sheet name:

[tt]=MID(CELL("FILENAME",F10),FIND("",CELL("FILENAME",F10))+1,255)[/tt]

In my version i had to tweak it a little to:

[tt]=MID(CELL("FILENAME",F10),FIND("]",CELL("FILENAME",F10))+1,255)[/tt]
 
Don't forget, file needs to have been saved first for it to work.

Regards
Ken...............

----------------------------------------------------------------------------
Attitude - A little thing that makes a BIG difference
----------------------------------------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top