IT's not possible to cut a protected cell.....if there is a formula in there, then lock the cell.
Copy a protected/locked cell, certainly. Cut a protected/locked cell, No Way. Check your code, don't reveal the password, make it a longer password. If you use VBA, then protect the project (from the VBA editor).
When you follow up with your users, do their memories of what happened agree with your suspicions? If they insist they didn't do what you accuse them of, then dig deeper.
How many formulas? You might want to consider removing the troublesome formulas from the sheet and have Worksheet_Change do the calculation.
My current project has tons of validation, cross-cell checking, etc., the only formula I use is in three cells: Today().
Also, Worksheet_SelectionChange may be of use, though I haven't used it. You could use the Intersect method and MsgBox users when they are where they shouldn't be.
But actually, now that I think of it, the best way to keep users out of locked cells is this:
sheet1.EnableSelection=xlUnlockedCells
If there is a formula in the cell, they have no business there, correct?
They can't select the cell.
And possibly:
Worksheets(1).ScrollArea = "a1:f10"
Which keeps them in the specific boundaries of the designated area. Also keeps them from selecting the entire sheet and pasting into another workbook; disabling the protection.
These commands would be placed in workbook_Open.
Yes, it's true, if macros are disabled, the safeguards won't be there. Is your problem malicious users, or unskilled users?
You can't stop a malicious user, just the unskilled ones.
You also need to make sure you and you only have Write privs on the folder where the file is stored. If you use SneakerNet, then by all means burn it onto a CD-ROM.
This is one possible scenario to corrupt a workbook:
Copy the sheet, paste into new workbook.
Save the workbook as the original workbook's name, back into the original location.
No More Protection.
If you aren't the only person capable of writing to that folder, then perhaps the above scenario is what happened?
Of course, if the PageSetup is intact, chances are the corrupted workbook is the original workbook.
This message was edited by stevebausch on 2002-09-11 16:56