Formula to Return Excel Sheet Name

KVASEY

New Member
Joined
Apr 10, 2006
Messages
11
=""&MID(CELL("filename",Sheet1!$A$1),FIND("]",CELL("filename",Sheet1!$A$1))+1,256)


1. Change filename to the your workbook's filename.
2. Change Sheet1 to your current sheetname where you have pasted the formula.



This formula below which I found on many forums doesn't really work because if you have it on 10 sheets and recalc, all 10 sheets will have the sheetname that is active.
=MID(CELL("filename"),FIND("]",CELL("filename"))+1,255)
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
You need to add a cell reference (without the sheetname) to make it specific to each sheet

=MID(CELL("filename",A1),FIND("]",CELL("filename",A1))+1,255)
 
Last edited:
Upvote 0
This thread has long been dormant but I created a Name (ThisWS) in the Name Manager with the following formula in the "Refers to:" section: =MID(CELL("filename",INDIRECT("A1")),FIND("]",CELL("filename",INDIRECT("A1")))+1,255). Referring to ThisWS (as =ThisWS) in any sheet returns the sheet name of the sheet (not just the last sheet calculated). Hope this helps.
 
Upvote 0

Forum statistics

Threads
1,214,901
Messages
6,122,157
Members
449,068
Latest member
shiz11713

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top