ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   insert file name (https://www.excelbanter.com/excel-discussion-misc-queries/24605-insert-file-name.html)

Mark

insert file name
 
Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark

Bob Tarburton


Mark

Filename
=MID(CELL("filename",A1),FIND("[",CELL("filename",A1))+1,(FIND("]",CELL("filename",A1))+1)-FIND("[",CELL("filename",A1))-2)

Sheet name
=MID(CELL("filename",A1),FIND("]",CELL("filename",A1),1)+1,255)

Full Address
=CELL("filename",A1)

Bob

On Tue, 03 May 2005 11:42:28 -0500, Mark wrote:

Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark



Duke Carey

=CELL("filename")

"Mark" wrote:

Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark


Bob Phillips

Mark,

Take a look at http://www.xldynamic.com/source/xld.xlFAQ0002.html

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mark" wrote in message
...
Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark




Bob Tarburton


=CELL("filename")

Careful, if you don't use a cell reference on the sheet this formula
will show the path/file/sheet you were on when you last recalculated.
Also, switching back to the sheet or printing will not automatically
recalculate.


"Mark" wrote:

Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark



Duke Carey

Excellent point!

"Bob Tarburton" wrote:


=CELL("filename")

Careful, if you don't use a cell reference on the sheet this formula
will show the path/file/sheet you were on when you last recalculated.
Also, switching back to the sheet or printing will not automatically
recalculate.


"Mark" wrote:

Hi,
Is there a way to program a cell to see and display the current name
of it's Excel file? Similar to the option displaying it in the header
or footer, I would like to display the file name in a cell of the
spreadsheet itself.
Any help would be appreciated.
Thanks in advance,
Mark





All times are GMT +1. The time now is 06:32 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com