Display a message when opening a template

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

Guest

I have created a template with fields that are completed by the end users.
Since many of the end users are not Word savvy, I would like to display a
message when they create a new doc (based on the template) that informs the
end users to look at the status bar for help instructions on how to complete
each field. How is this accomplished? I'm guessing a macro and vba - if so,
please use as much "simpleton" language as possible. I have a basic
understanding of vba - via working with MS Access - but am self taught and
the online help confuses the begeebers out of me.

Thank you so very much for sharing your expertise and kindness.
 
You can do this:
In your template, create a macro named AutoNew (can be stored in any code
module in the template). That macro will automatically run when a new
document based on the template is created. Use the MsgBox function to display
the message to the user. Your macro could look like this:

Sub AutoNew()

MsgBox Prompt:="Please fill out the form." & vbCr & _
"Look at the status bar for help instructions on how " & _
"to complete each field.", _
buttons:=vbOKOnly + vbInformation, _
Title:="How to fill out this form"

End Sub

If you also want the information to be shown if a user opens an existing
form, you can create a macro named AutoOpen. The AutoOpen macro below simply
calls the AutoNew macro, i.e. it runs the same code as the AutoNew macro.

Sub AutoOpen()
AutoNew
End Sub

See the VBA help for information about the "MsgBox Function".

For information about installing macros, see:
http://www.gmayor.com/installing_macro.htm

For information about AutoMacros, see:
http://word.mvps.org/faqs/macrosvba/DocumentEvents.htm

--
Regards
Lene Fredborg
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word
 

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