Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / March 2006

Tip: Looking for answers? Try searching our database.

Macro code to remove a macro after it executes

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Charles - 21 Mar 2006 20:21 GMT
After I run a macro to format an Excel worksheet, I would like to be able to
permanently remove all the macro code so that when a new user is sent the
formatted Excel worksheet, there is no pop-up window warning about Macros and
there are no Macros within the macro window.

What would be the code to have a macro permanently erase itself, without at
trace, from an Excel worksheet
Jim Thomlinson - 21 Mar 2006 20:48 GMT
Check out this link...

http://www.cpearson.com/excel/vbe.htm
Signature

HTH...

Jim Thomlinson

> After I run a macro to format an Excel worksheet, I would like to be able to
> permanently remove all the macro code so that when a new user is sent the
[quoted text clipped - 3 lines]
> What would be the code to have a macro permanently erase itself, without at
> trace, from an Excel worksheet
Charles - 21 Mar 2006 22:39 GMT
I appreciate the help.  Not being a programmer I am unsure as to which of the
many codes listed will do the one I want as well as to how to append it to
have it as a single macro instead of multiple.

Please advise.

> Check out this link...
>
[quoted text clipped - 7 lines]
> > What would be the code to have a macro permanently erase itself, without at
> > trace, from an Excel worksheet
Dave Peterson - 22 Mar 2006 01:09 GMT
How about just putting the macro into a different workbook.

Then you can open the macro workbook whenever you need to.

Make sure the worksheet to be formatted is active
tools|macro|macros...|and run your code.

Then you don't have to keep more than one copy of the code and never have to
worry about removing it from the data workbook.

> After I run a macro to format an Excel worksheet, I would like to be able to
> permanently remove all the macro code so that when a new user is sent the
[quoted text clipped - 3 lines]
> What would be the code to have a macro permanently erase itself, without at
> trace, from an Excel worksheet

Signature

Dave Peterson

Charles - 22 Mar 2006 13:11 GMT
This is a good idea, however, the outcome is to have all macros removed from
the file itself so that when the macro finishes running, the file can be sent
to people free of macros.

Please advise.

> How about just putting the macro into a different workbook.
>
[quoted text clipped - 13 lines]
> > What would be the code to have a macro permanently erase itself, without at
> > trace, from an Excel worksheet
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.