prevent saving a worksheet

L

looking4help

When I post my worksheet to my website, I want the user to be able to use the
filtering functions I have in the worksheet but I don't want them to be able
to save the worksheet to their hard drive.

Is there a way that I can do this?

Thanks!
 
G

Gary Brown

In the 'ThisWorkbook' code section of the workbook, put...

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
Cancel = True
End Sub

Of course, if they have macros set to not run, this won't work.

HTH,
Gary Brown
 
G

Gord Dibben

If on a website, I don't know of a method to prevent a user from right-click
and Save Target As.

Unless your website can restrict that capability?

Excel certainly can't prevent it.


Gord Dibben Excel MVP
 
Top