
I am seeing a ghost in the list of macros in Word 2002
That would wipe out other customizations.
In any case, I found a simple workaround that executes much more quickly,
it's better code too.
Instead of creating a temporary module, modifying the code, and using
Organizer as I indicated, I found that the problem is avoided and the code
runs much faster if I instead do the following:
1. Export each module from the Source template.
2. Import each module into the new template.
3. Make the modifications in the new template.
This avoids the apparent bug using Organizer since a temporary module is
never created in the Source template.
And it seems to execute more than 20% faster. In a few minutes, I'll try a
test that took about 42 minutes with the old code to see how much quicker it
runs.
--
http://www.standards.com/; Programming and support for Word macros,
including converting from WordBasic to VBA; Technical reviewing; Standards;
Product functional/design/specifications
------------------------------------------------
Quote:
> How about utilizing the Reset method of the commandbar
> control that brings up the Macro dialog?
> Kind regards,
> Perry
> > I've been programming the VBIDE to modify the modules in a template and
> > create a brand new template containing the modified modules.
> > In general, I:
> > 1. Modify the code in the original template using a temporary module,
> let's
> > call this, "ship".
> > 2. Use OrganizerCopy to copy to the new template.
> > 3. Use OrganizerRename to rename the module in the new template.
> > 4. Use OrganizerDelete to remove "ship" from the original template.
> > After the deed is done, if I close the VBIDE and look at Tools | Macros
in
> > Word, I see that a macro in the last copy of "ship" is listed in the
> macro
> > list even tho the "ship" module no longer exists. I verified that the
> module
> > no longer exists by running a macro that lists the project components.
If
> I
> > try to access the macro with the Edit button in Tools | Macros, I get a
> > message box that tells me there's no such critter.
> > If I exit from Word and restart Word, the ghost macro is no longer
listed.
> > I was able to reproduce this by starting over with a clean template
file.
> > I did not notice the problem until a few hours ago.
> > Anybody know how to get around this?
> > --
> > http://www.standards.com/; Programming and support for Word macros,
> > including converting from WordBasic to VBA; Technical reviewing;
> Standards;
> > Product functional/design/specifications
> > ------------------------------------------------