Can I autotext a filepath only?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can I create or modify an autotext entry to show only the path to a file and
not the name of the file (document). I need the path as a location in the
footer but the document name is already included elsewhere.
I'm using Word 2003 at work.
 
I don't see why not. Have you tried it?

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA

Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 
The following macro will insert the path of the active document.

Sub InsertPath()
Dim pPathname As String
With ActiveDocument
If Not .Saved Then
.Save
End If
pPathname = Left$(.FullName, (Len(.FullName) - Len(.Name) - 1))
End With
Selection.TypeText pPathname
End Sub

http://www.gmayor.com/installing_macro.htm
--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP

My web site www.gmayor.com

<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top