skylark_za said:
I am wanting to show the name of the document in the footer but
without the document extension (.doc) Please could somebody explain
how I would do this.
Thanks
You cannot do it with a field, but it is easy enough to achieve with a
macro. The first macro will insert the name and path, the second just the
name.
Sub InsertfNameAndPath()
Dim fname, fname2, pathname As String
If ActiveDocument.Saved = False Then ActiveDocument.Save
fname = Selection.Document.FullName
fname2 = Selection.Document.Name
pathname = Left(fname, (Len(fname) - 4))
Selection.TypeText pathname
End Sub
Sub InsertFnameOnly()
Dim fname, fname2 As String
If ActiveDocument.Saved = False Then ActiveDocument.Save
fname2 = Selection.Document.Name
fname = Left(fname2, (Len(fname2) - 4))
Selection.TypeText fname
End Sub
See
http://www.gmayor.com/installing_macro.htm
--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP
My web site
www.gmayor.com
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>