Forum Discussion
SuzanH
May 15, 2019Copper Contributor
Insert File name via an array formula
I've just discovered this tool, fantastic.
BUT, can the field be amended to remove the file extension? I want to use the field within a report as the document reference, but without the .xlsx
Thanks
2 Replies
- TwifooSilver ContributorThis formula returns the file name without the file extension:
=MID(CELL("filename",A1),
FIND("[",CELL("filename",A1))+1,
FIND(".x",CELL("filename",A1))-FIND("[",CELL("filename",A1))-1) - SergeiBaklanDiamond Contributor
SuzanH , do you mean this https://support.office.com/en-ie/article/insert-the-current-excel-file-name-path-or-worksheet-in-a-cell-186833c6-c899-4912-a14c-240c2eb51e0b formula?
It returns something like path\[filename.xlsx]Sheet1 and you'd like path\[filename]Sheet1, correct?