Directory for Word documents

camtz
camtz used Ask the Experts™
on
Is there a way to have Word, Excel show the directory at the top of the page so that I know where the document is stored on the computer using Windows 10? Thanks
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
NVITEnd-user support

Commented:
There doesn't seem to be a built-in way to do that. You'll need to use a macro.

https://word.tips.net/T001248_Full_Path_Names_in_Word.html

There are a couple of ways that this can be approached. If you only need to know the full path name once in a while, then you can create a very simple macro and assign it to a toolbar button. When you click on the button, the information in the title bar for the active window is changed to reflect the full path name. This macro, called ChangeCaption, is as follows:

Sub ChangeCaption()
    ActiveWindow.Caption = ActiveDocument.FullName
End Sub

Open in new window


There are a couple of big drawbacks to this option, however. Whenever you rename the document by using Save As to save it under a different name, the new file name (and path) are not updated in the title bar unless you rerun the macro. Secondly, if you have virus checking turned on, then it may interpret your macro (assigned to AutoOpen) as an attempt by a macro virus to mess with your system.

There is a way to create a more comprehensive and automatic approach... Essentially, the steps used in accomplishing this approach are as follows:
1. Set up Word to trigger application events (they're built in to Word, but they don't happen automatically).
2. Write some the actual title-bar changing code for the DocumentChange event.

Then explains how to setup the approach, including related macro code.
John KorchokProduction Manager

Commented:
In Word, use Insert>Quick Parts>Field and choose Filename. Check the box in the dialog to add the path. Place this in the page header to display it on every page. Add it to your Normal.dotm template to ensure it appears in every document.

In Excel, choose the Page Layout tab, then open the Page Setup dialog. Click on the Header/Footer tab, then click on Custom Header. Click on the Insert File Path button, which adds both the path and file name to the header. Repeat for each worksheet where you want the info to appear. If you save the resulting file in the Excel Startup directory and call it book.xltx, the file name and path with appear on all new workbooks without any effort on your part.
the simple way to do this is to add Document Location to the Quick Access Toolbar (both Word & Excel have this option available)

Options ―> Quick Access Toolbar ―> Commands Not in the Ribbon ―> Scroll down to Document Location and select ―>click on Add

EDIT:
this way, you don't have to put it in every document!

Author

Commented:
Paul, I have looked for Quick Access Toolbar in Word but can't find it.  Sending a pic of what mine looks like.  Can you give me more instructions please.This is what Options looks like
John KorchokProduction Manager

Commented:
In Word 2007, click on the Customize option to find the QAT commands.
perhaps also from here:QAT

Author

Commented:
Thank you, I found it.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial