Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Troy
 
Posts: n/a
Default I want a cell to show the current filename automatically.

I am trying to set up a spreadsheet for work. I want a specified cell to
automatically show the filename of the current file.
  #2   Report Post  
Posted to microsoft.public.excel.misc
SteveG
 
Posts: n/a
Default I want a cell to show the current filename automatically.


Troy,

In the cell that you want the filename to appear.

=CELL("filename",A1)

Reference can be any cell in the workbook. It will show the full path
and sheet like.

C:\Documents and Settings\doeJ\My Documents\[Filename.xls]Sheet1


HTH

Steve


--
SteveG
------------------------------------------------------------------------
SteveG's Profile: http://www.excelforum.com/member.php...fo&userid=7571
View this thread: http://www.excelforum.com/showthread...hreadid=506751

  #3   Report Post  
Posted to microsoft.public.excel.misc
Troy
 
Posts: n/a
Default I want a cell to show the current filename automatically.

But what if I want only the file anme to show and not the entire path? Also,
what exactly goes in the cell? I am looking at your post and not sure how to
insert the information.

"SteveG" wrote:


Troy,

In the cell that you want the filename to appear.

=CELL("filename",A1)

Reference can be any cell in the workbook. It will show the full path
and sheet like.

C:\Documents and Settings\doeJ\My Documents\[Filename.xls]Sheet1


HTH

Steve


--
SteveG
------------------------------------------------------------------------
SteveG's Profile: http://www.excelforum.com/member.php...fo&userid=7571
View this thread: http://www.excelforum.com/showthread...hreadid=506751


  #4   Report Post  
Posted to microsoft.public.excel.misc
Sloth
 
Posts: n/a
Default I want a cell to show the current filename automatically.

You must save the file at least once before these formulas will work.

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

returns name -without extension "Filename"

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

returns name with extension "Filename.xls"


"Troy" wrote:

But what if I want only the file anme to show and not the entire path? Also,
what exactly goes in the cell? I am looking at your post and not sure how to
insert the information.

"SteveG" wrote:


Troy,

In the cell that you want the filename to appear.

=CELL("filename",A1)

Reference can be any cell in the workbook. It will show the full path
and sheet like.

C:\Documents and Settings\doeJ\My Documents\[Filename.xls]Sheet1


HTH

Steve


--
SteveG
------------------------------------------------------------------------
SteveG's Profile: http://www.excelforum.com/member.php...fo&userid=7571
View this thread: http://www.excelforum.com/showthread...hreadid=506751


  #5   Report Post  
Posted to microsoft.public.excel.misc
Gary''s Student
 
Posts: n/a
Default I want a cell to show the current filename automatically.

=CELL("filename",B1) in B1. Will display path as well as filename
--
Gary''s Student


"Troy" wrote:

I am trying to set up a spreadsheet for work. I want a specified cell to
automatically show the filename of the current file.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I move the current cell to the top of the screen? mad.cow Excel Discussion (Misc queries) 6 May 29th 05 05:35 AM
enter a time into a cell, have the cell show two times the entry johnp Excel Worksheet Functions 3 May 2nd 05 12:08 AM
Changing cell references automatically Bigweed New Users to Excel 3 April 28th 05 12:27 PM
Changing Cell formats to date fields automatically PCLIVE Excel Worksheet Functions 3 April 12th 05 10:34 PM
how do i insert the current time into a cell, and show different . Dave Excel Discussion (Misc queries) 1 March 22nd 05 06:57 PM


All times are GMT +1. The time now is 05:08 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"