My add-in .DOT's VBA events don't fire

A

Avi

Hi all,

Word 2003 vba: How can I activate the VBA events of a .DOT I attached as
an "add-in"; alternatives? wll file?

I have just completed writing part of a fairly complex VBA utility for
controlling Word. This utility makes use of a number of events including
Document_New and Document_Open.

First of all I just designed the forms, code and events in the doc's
*template*, coz it was just convenient.

Now, I needed to apply this utility to a different document, so I decided
that it was time to see if I could add it all as an "add-in" (using
Tools|Templates and Add-ins|Add). So I made a different DOT file containing
all my VBA stuff and saved it to disk, calling it *something.dot*. Then I
*added it* to my doc, as above. Then, to test if the Document_Open would be
invoked when I then re-open my doc, I closed the document and then re-opened
it. Lo and behold...

the Document_Open event was NOT invoked.

I also made sure that the .DOT add-in was also open before I opened my doc,
to see if that would help, and it did not help.

Why is life so difficult...?

Anyway...so I understand you can't get your doc to connect with events this
way? If not, so what's the simplest alternative way of achieving this?

And btw, I see from the Add-in dialog box, you can also add in WLL files.
What are these and how do you make them?

Tnx,

- avi
 
D

Doug Robbins - Word MVP

Where did you save the template that you want to be treated as an add-in.
It needs to be saved into the Word Startup folder the location of which is
shown under Tools>Options>File Locations.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 
D

Doug Robbins - Word MVP

I can't answer your BTW question except to say that the .PDF maker toolbar
is not visible in Word 2003 on my machine, though it is visible in Excel,
that being because the PDFMaker.xla template is in the XLSTART Folder under
c:\Program Files\Microsoft Office\Office11\XLSTART

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 
P

Perry

Look for the PDFMaker.dot in the Office startup folder.

If Microsoft Office is installed on a (standalone) computer -Non Enterprise
rollouts- the
location is:
C:\Program Files\Microsoft Office\OFFICE11\STARTUP

If it concerns an Enterprise rollout of MS Office, the above location
could be another location. In such case, ask your IT ops department for
the install directory of MS Office ...

Krgrds,
Perry
 

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