;1603139']On Mon, 25 Jun 2012 12:29:45 +0000, Moideen
Dear Gord ,
Thank you very much, It's Function working well, But i unprotected the
work sheet with the password of "justme" and excel opening time need
auto protection if i forgot to protect the sheet before excel closing
time.
your kindly help is highly appreciated-
Copy/paste this event code to Thisworkbook module.
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Sheets("yoursheetname").Protect Password:="justme"
End Sub
NOTE: as others have pointed out, Excel's internal security is quite
weak and protection of cells and sheets will serve only to prevent
accidental overwriting of formulas or data.
A user determined to change data can easily crack the password
protection.
GS also asked "how will user correct a mistake in data entry if cells
are locked"?
What will you do if users do not enable VBA when they open the
workbook?
Have you considered these issues?
Gord