Inserting Filename?

  • Thread starter Thread starter Bill Allen
  • Start date Start date
B

Bill Allen

How does one insert a filename into a cell?

That's part (A.) of the question.

Part B: If the file name is "12345name.xls", how do I just insert "name"?
The preceeding numbers (12345 in this example) for me will always be five
digits.

TIA,

Bill
 
Hi
A: Use (just insert the formulas as-is. Note: the workbook has to be
saved before)
=MID(CELL("filename",A1),FIND("[",CELL("filename",A1),1)+1,FIND("]",CEL
L("filename",A1),1)-FIND("[",CELL("filename",A1),1)-1)


B.
=MID(CELL("filename",A1),FIND("[",CELL("filename",A1),1)+6,FIND("]",CEL
L("filename",A1),1)-FIND("[",CELL("filename",A1),1)-1)
 
Thanks, Frank.

Bill

Frank Kabel said:
Hi
A: Use (just insert the formulas as-is. Note: the workbook has to be
saved before)
=MID(CELL("filename",A1),FIND("[",CELL("filename",A1),1)+1,FIND("]",CEL
L("filename",A1),1)-FIND("[",CELL("filename",A1),1)-1)


B.
=MID(CELL("filename",A1),FIND("[",CELL("filename",A1),1)+6,FIND("]",CEL
L("filename",A1),1)-FIND("[",CELL("filename",A1),1)-1)


--
Regards
Frank Kabel
Frankfurt, Germany


Bill said:
How does one insert a filename into a cell?

That's part (A.) of the question.

Part B: If the file name is "12345name.xls", how do I just insert
"name"? The preceeding numbers (12345 in this example) for me will
always be five digits.

TIA,

Bill
 
Back
Top