Free Excel UDF to display the name of the current Excel workbook, including the workbook extension. This function has no arguments and is very easy to use. Simply enter the function into any spreadsheet and the function will return the full name and extension of that spreadsheet.
This is a great function to use when you need to keep tabs on what version of an Excel file you are working with as well as on any master worksheet within a spreadsheet.
Function WORKBOOKNAME()
WORKBOOKNAME= ThisWorkbook.Name
End Function