Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Setup / March 2005

Tip: Looking for answers? Try searching our database.

Full Pathname in Titlebar

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Greg - 24 Mar 2005 03:43 GMT
How do I display a filename's full pathname in the titlebar (i.e. "c:\my
documents\filename" instead of just "filename").
Signature

Greg

Gord Dibben - 24 Mar 2005 18:35 GMT
Greg

No setting, but code.......copy/paste the code below into the ThisWorkbook
Module of your workbook.

Private Sub Workbook_Open()
   ActiveWindow.Caption = ActiveWorkbook.FullName
End Sub

Right-click on the Excel logo at top left of Menubar and select "View Code".

Paste in there.

Save the workbook.

OR....use this Toggle macro.

Sub CaptionToggle()
' toggles title bar between document name and full path
   If ActiveWindow.Caption = ActiveWorkbook.Name Then
       ActiveWindow.Caption = ActiveWorkbook.FullName
   Else: ActiveWindow.Caption = ActiveWorkbook.Name
   End If
End Sub

Gord Dibben Excel MVP

>How do I display a filename's full pathname in the titlebar (i.e. "c:\my
>documents\filename" instead of just "filename").
David McRitchie - 24 Mar 2005 20:19 GMT
I used to use Auto_Open for this and I know it interfered
with me in some way.   In any I'd rather have a shorter
name that is correct than a full pathname that is incorrect.

If you have two workbooks open as you switch between them
one of them will be incorrectly marked on the title bar if you
are viewing the spreadsheet maximized within the Excel window.

The following will work better and would be placed in "ThisWorkbook"

Private Sub Workbook_WindowActivate(ByVal Wn As Window)
 ActiveWindow.Caption = ActiveWorkbook.FullName
End Sub

I will change my   pathname.htm   web page to show the above
a a preference to  Auto_Open.    I tried using an deactivate as well
but it seemed to gain nothing.  And the title bars of the worksheet when normal or whater not maximized is called then both had
their own correct pathnames regardless of which was active.  (both title bars as well
as the Excel window titlebar all being visible)
---
HTH,
David McRitchie, Microsoft MVP - Excel    [site changed  Nov. 2001]
My Excel Pages:  http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page:        http://www.mvps.org/dmcritchie/excel/search.htm

> Greg
>
[quoted text clipped - 25 lines]
> >How do I display a filename's full pathname in the titlebar (i.e. "c:\my
> >documents\filename" instead of just "filename").
Dave Peterson - 25 Mar 2005 02:49 GMT
David,

Bob Phillips and I had a recent thread discussing the same issue.  We used an
application event (with references to both your and Chip Pearson's site!).

If you want to steal/modify any of the stuff we did, it's ok with me.  I bet Bob
would say ok, too.  (Heck it's on google, so he can't be too upset <bg>.)

http://groups.google.co.uk/groups?threadm=42231CA3.B4473A68%40netscapeXSPAM.com

(It's ok if you don't want to use any of it, too.)

> I used to use Auto_Open for this and I know it interfered
> with me in some way.   In any I'd rather have a shorter
[quoted text clipped - 50 lines]
> > >How do I display a filename's full pathname in the titlebar (i.e. "c:\my
> > >documents\filename" instead of just "filename").

Signature

Dave Peterson

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.