View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
JLGWhiz JLGWhiz is offline
external usenet poster
 
Posts: 3,986
Default Protected VB code - Run-time error

Couldn't duplicate the error. Mine saves as without a problem and retains
the protection.

"AvalancheMike" wrote:

My code runs fine, however when I protect the code from viewing I get the
following run-time error:

Method 'SaveAs' of object'_Workbook' failed

Here is the only code I have for saving the file:
ActiveWorkbook.SaveAs Filename:=SourceName, FileFormat:=xlTextPrinter,
CreateBackup:=False

TIA