View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Jon Peltier Jon Peltier is offline
external usenet poster
 
Posts: 6,582
Default Why is this so ?

What's your virus software? What version of Excel is it?

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
http://PeltierTech.com
_______


"Jason Zischke" wrote in message
...
Hi all,

I found this code that exports, Removes & imports forms, modules & class
modules however I can't seem to get the remove to work and when I go to
save
the workbook my virus protector sees it as a threat or a possible virus so
it
then prohibits excel from saving. See below for the code and any help
would
be greatly appreciated.

Sub TestExportForm()
ThisWorkbook.VBProject. _
VBComponents("Userform1").Export "C:\Userform1.frm"
ThisWorkbook.VBProject.VBComponents.Remove "Userform1"
End Sub

Sub TestImportForm()
ThisWorkbook.VBProject.VBComponents.Import "C:\Userform1.frm"
End Sub


Jason