View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
david mcritchie david mcritchie is offline
external usenet poster
 
Posts: 691
Default Can a macro delete itself?

Hi Mike,
Sure, see Chip Pearson's page.
Coding to the VBE
http://www.cpearson.com/excel/vbe.htm
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"OceansideDJ" wrote in message ...
My auto_run macro imports a text file, formats a report, asks the user for a
FileSaveAs filename, and finally saves a copy of the spreadsheet.

Now, I do not want the macro to run again, in this saved copy. Can the macro
delete itself, or rename itself, or disable itself, or save a copy of the
spreadsheet with no macros? Anythng to never run again.

Thanks,

Mike