How can I create new Word VBA project?

M

Mike NG

Each Word template can contain only one project. So if you want a new
project, create a new template.
Will this be the answer to my problem previously posted - "how do I
attach some VBA code to a newly created word doc" ? If so, I'd be most
grateful of how to do it.

Basically, what I want is whenever newly created word docs are closed
down, I want to run a small piece of code
 
J

Jonathan West

Mike NG said:
Will this be the answer to my problem previously posted - "how do I
attach some VBA code to a newly created word doc" ? If so, I'd be most
grateful of how to do it.

Basically, what I want is whenever newly created word docs are closed
down, I want to run a small piece of code

Code for this is better put into the template that the document is based on.
This article will help you write event-based code

Running a macro automatically when a document is created, opened or closed
http://www.mvps.org/word/FAQs/MacrosVBA/DocumentEvents.htm


--
Regards
Jonathan West - Word MVP
MultiLinker - Automated generation of hyperlinks in Word
Conversion to PDF & HTML
http://www.multilinker.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

Top