HOW TO PROTECT SAVEAS FILE

K

K

Hi all, I am using excel 2007. i have code (see below) in my macro
which save my file into "mht" "Single File Web Page" format.

CODE:===========================>

Range("A13:L58").Select
With ActiveWorkbook.PublishObjects.Add(xlSourceRange, _
"C:\Documents and Settings\" & Range("A13").Value & " ( " &
Range("K16").Value & " )" & " - " & Range("K13").Value & ".mht", _
ActiveSheet.Name, "$A$13:$L$58", xlHtmlStatic, , "")
..Publish (False)
..AutoRepublish = False
End With
Range("B27").Select
End If
End Sub

<================================
My question is that how can i protect file sheet the one saved as in
"Single File Web Page" format so no one can make changes in it. I
know its some thing goes under ".AutoRepublish = False" but not sure.
Actually I am saving my 'Excel Macro-Enabled Workbook" format file
into "Single File Web Page" format which my other colleagues will open
in excel to view but i need some code line which should protect the
sheet of file which will be saved as "Single File Web Page" Format.
Please can any body help
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top