PDA

View Full Version : Save a new copy of file "without" the macro



schneidm
01-25-2010, 08:38 AM
I have a master ppt file that I use for updating. I have a macro that breaks all the links and saves a new copy for distribution. Is there a way to save the new copy so it does not include the macro in the master file? Or, delete the macro from the new file and resave? I'd like to avoid getting the macro warning on the new copy of the file for anyone that opens it.

Cosmo
01-25-2010, 03:09 PM
Hmm, don't know what happened to the response I posted earlier. Seems to have disappeared from the forum.

Here's the code I use to remove a few specific modules from a presentation:
MasterFile.VBProject.VBComponents.Remove.VBComponents("ModuleToDelete")

Where 'MasterFile' is a reference to your master PPT file, and 'ModuleToDelete' is the name of the module you want to delete.

John Wilson
01-25-2010, 03:35 PM
I would put the code in an addIn or at least in second presentation.

There are instructions on www.pptfaq.com on creating a simple addin with a toolbar.