Exceljet

Quick, clean, and to the point

Get sheet name only

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

If you want to get the sheet name only (i.e. the sheet name without the file name or path) you can do so with rather long formula that uses the MID function along with the FIND function. The final result will look something like this:

Sheet1

How the formula works

The cell function is used to get the full file name and path:

CELL("filename",A1)

The result looks like this:

path[workbook.xlsm]sheetname

The full file name plus path and sheet is fed into the MID function, which is used to extract just the sheet name.

The starting position is calculated with FIND:

FIND("]",CELL("filename",A1))+1

The number of characters to extract is supplied as 255. In the Excel UI, you can't name a worksheet longer than 31 characters, but the file format itself permits worksheet names up to 255 characters.

Alternative with RIGHT

Several readers have mentioned an alternative like this with the RIGHT function:

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

A few more function calls, but a perfectly valid formula.

Author 
Dave Bruns

Excel Formula Training

Formulas are the key to getting things done in Excel. In this accelerated training, you'll learn how to use formulas to manipulate text, work with dates and times, lookup values with VLOOKUP and INDEX & MATCH, count and sum with criteria, dynamically rank values, and create dynamic ranges. You'll also learn how to troubleshoot, trace errors, and fix problems. Instant access. See details here.