You might consider protecting the sheets using the UserInterfaceOnly
parameter. This prevents the user from modifying the worksheet but
allows VBA to do anything it wants, regardless of protection. This
property does not stick with the worksheet when the file is closed, so
you should use something like the following, in the ThisWorkbook
module:
Private Sub Workbook_Open()
Dim WS As Worksheet
For Each WS In ThisWorkbook.Worksheets
WS.Protect UserInterfaceOnly:=True
Next WS
End Sub
This will protect all the sheets from user modification but will allow
your VBA code to run without protection problems.
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)