» Cell Function Returns Sheet Name, Workbook Name and Path
CATEGORY - Excel Tools
VERSION - All Microsoft Excel Versions
To get the sheet name:
=MID(CELL("filename"),FIND("]",CELL("filename"))+1,255)
To get the workbook name:
=MID(CELL("filename"),FIND("[",CELL("filename"))+1,(FIND("]",CELL("filename"))+1)-FIND("[",CELL("filename"))-2)
To get the path address & workbook name:
=CELL("filename")
To get the path address:
=MID(CELL("filename"),1,FIND("[",CELL("filename"))-1)

Book Store:
Recommended Books:
- Special Edition Using Microsoft Outlook 2002
- Financial Risk Manager Handbook, Second Edition
- Real Estate Finance and Investments (Real Estate Finance and Investments, 11th Ed)
- Microsoft Excel 2002 Formulas (With CD-ROM)
- Microsoft Office Xp: Advanced Concepts and Techniques: Word 2002, Excel 2002, Access 2002, Powerpoint 2002
- The 11 Immutable Laws of Internet Branding
Nice but...
I notice that if you have multiple sheets and you enter this formula on them, then all sheets have the same value as the last time you ran the formula...
Very much Interesting
Ganesh Dabholkar-INDIA Mumbai
I really appreciate, by your Excel tips.
From past 3 months I am trying for the same.
Once again Thanks for the same
RE: Nice but...
If you add a cell reference to the first CELL function like this:
=MID(CELL("filename",A1),FIND("]",CELL("filename"))+1,255) it will reference the current sheet instead of the sheet you were in the last time you ran the formula.
Wonderful !
venkat
suggestions on Formating cells are most welcome. Also tell us more formulaes, esp: on VLOOKUP.
Also note if you only have one sheet...
Chief~Plasma
If you only have one sheet then the finds for [ and ] will fail and you will get #value!.
Regards,
-cp

