Re: Dynamically adding vba modules to word application
- From: Jay Freedman <jay.freedman@xxxxxxxxxxx>
- Date: Mon, 17 Dec 2007 22:02:00 -0500
It's theoretically possible, but Word will fight you all the way if
you try to do it. Code that adds or modifies code is classic virus
behavior, so you have to go to extreme lengths to work around the
security mechanisms.
Fortunately, it isn't necessary for your use case. Simply put your
code into a separate template, and have the client place that template
in their Startup folder (the location is shown in the Tools > Options
File Locations dialog). The template will be loaded as a globaltemplate every time Word starts, and the code will be available in all
documents.
On Mon, 17 Dec 2007 18:07:38 -0800 (PST), samlotti@xxxxxxxxx wrote:
Hello,
Im trying to create a word document with a bootstrap vba module that
will insert modules dynamically at runtime. Is there a way to do
this?
The real use cae is that I have a large (1m) in vba template code that
I want to send to a client. But since its so large, Ide like o send
it one and store it locally, the each time they download one of our
documents it is basically a bootstrap that loads the real vba macro.
Thanks
Sam
--
Regards,
Jay Freedman
Microsoft Word MVP FAQ: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit.
.
- References:
- Dynamically adding vba modules to word application
- From: samlotti
- Dynamically adding vba modules to word application
- Prev by Date: Dynamically adding vba modules to word application
- Next by Date: Get Open File Name dialog. When user clicks cancel.
- Previous by thread: Dynamically adding vba modules to word application
- Next by thread: Get Open File Name dialog. When user clicks cancel.
- Index(es):
Relevant Pages
|
Loading