Save Option on Protected Worksheet

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can I supress the " Do you want to save changes" . I have created a worksheet used by multiple users, they enter their data get their results and close the file. The worksheet is protected but I do not want them to get the option to save.
 
The events must be placed in the Thisworkbook module

You can add this event to the workbook if you don't
want to save the workbook

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Saved = True
End Sub

And this if you always want to save

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Save
End Sub



--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)




Shellj said:
Can I supress the " Do you want to save changes" . I have created a worksheet used by multiple users, they enter their data
get their results and close the file. The worksheet is protected but I do not want them to get the option to save.
 
I don't know if there's a better way in Excel itself, but if you make the
file read-only in Windows Explorer (right-click on file, select Properties,
select Read-only check box and Apply the change), although the user is still
prompted to save the changes, they must save under a different filename,
therby retaining your original file.

Ian

Shellj said:
Can I supress the " Do you want to save changes" . I have created a
worksheet used by multiple users, they enter their data get their results
and close the file. The worksheet is protected but I do not want them to
get the option to save.
 
Back
Top