Complete Properties details first

D

Dean Jones

Hi All,

Newbie here so sorry if this has been aasked before.

I have created a word (2003) template which uses the file properties fields
in the document text, e.g. Title and Author.

My question is how can I get someone to complete these fields when the
template is open. Looked at the ask and fillin but very basic knowledge on
scripting and/or macros.


Regards


Dean
 
G

Graham Mayor

One simple method .....If you create a new document from your template
containing the following macro, you will not be able to enter anything in
the document while the Title field is empty. The macro populates the Author
field from the User Information (which it should anyway).

Sub AutoNew()
Start:
With ActiveDocument
.BuiltInDocumentProperties(wdPropertyAuthor) = Application.UserName
Dialogs(wdDialogFileSummaryInfo).Show
If .BuiltInDocumentProperties(wdPropertyTitle) = "" Then
MsgBox ("You must enter the document title before proceeding")
GoTo Start
End If
End With
End Sub

http://www.gmayor.com/installing_macro.htm


--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP


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

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

Top