View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Vasant Nanavati Vasant Nanavati is offline
external usenet poster
 
Posts: 1,080
Default Trying to protect output file with Macro

Read-Only Recommended does not make the file read-only.

You need to set the WriteResPassword to make the file read-only.

--

Vasant

"dumbass" wrote in message
...
Hi-
after a user processes my spreadsheet, an output file is created which I

would like to save as a protected text-file, read-only. But somehow my macro
does not put any protection on the output file, nor is it read-only. Here is
the code:

Sheets("BranchOutputCheck").Select
ActiveWorkbook.SaveAs Filename:= _
netwrkpath2, FileFormat:=xlText, _
password:=pswd, ReadOnlyRecommended:=True, CreateBackup:=False

Thanks for the help!