How "launch upon opening" document

G

George

Am using WordXP. Created a simple document template for business letterhead
and used macro recorder to drop down a few spaces excecute a few clicked
commands.

How can I get this macro to trigger itself and run every time upon opening
this template? Is there a checkbox somewhere to choose this, or do I have
to "edit" the script, which could be difficult for an amateur.
 
G

George

Thanks Jezebel,
Just a brief add-on question. Since there can only be one thing named
AutoOpen in a given document, what if I name an AutoOpen in the NORMAL
template, which I understand somehow invokes its macros globally, and also
create an AutoOpen in my LETTERHEAD.dot template... is this possible and
which one would overrule the other (assuming the AutoOpen script is
different in each file). Or do both tasks get done?
Thanks
 
C

Charles Kenyon

Haven't tried it recently, but when I tried this in Word 97 the macro in the
document template ran and the one in normal.dot did not.

However, if you are properly creating new documents based on your template
rather than opening your template, you want your macro named AutoNew instead
of AutoOpen. AutoOpen does _not_ run when a new document is created.
--

Charles Kenyon

See the MVP FAQ: <URL: http://www.mvps.org/word/> which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 
P

Peter Hewett

Hi George

Just to add expand upon what Charles has said. The macros: AutoNew,
AUtoOpen, Document_New, Document_open in Normal.dot are only triggered if
you're creating a document or opening a document based on the Normal.dot
template. If you're opening or creating a document based on your own
template then the macros in your template will be executed.


If you have the same macros (say AutoOpen) in both your template and
Normal.dot the AutoOpen in your template will be triggered NOT the one in
Normal.dot. The exception to this is if Word cannot find your template, in
that case Word will attach your document to Normal.dot and fire it's
AutoOpen macro.

HTH + Cheers - Peter
 

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