Results 1 to 2 of 2
2008-07-01, 05:08 #1
- Join Date
- Apr 2003
- Kansas City, Missouri
- Thanked 0 Times in 0 Posts
Cannot override Unprotect Document command (Word 2003 SP 3)
I am trying to incorporate code that warns a user against unprotecting a document. I'm having trouble overriding the Unprotect command though. When I try it out, I unprotect the document with no message box.
Am I doing the command wrong? Here is what I have:
If MsgBox("Please note that the automated features of this form rely on the document's " & _
"form elements " & _
"remaining unchanged. Unprotecting the form could lead to file corruption and an error "& _
"in running" & _
"the automated features." & vbCr & vbCr & "Are you sure you wish to unprotect the form?", _
"Unprotect Detected") = vbYes Then
I appreciate any assistance you can offer.
2008-07-01, 08:19 #2
- Join Date
- Mar 2002
- Thanked 30 Times in 30 Posts
Re: Cannot override Unprotect Document command (Word 2003 SP 3)
Your macro works for me in Word 2002, but it only traps the Tools | Unprotect Document menu command, not the Protect / Unprotect button on the Forms toolbar, and I assume it won't work with the Protect Document task bar (or whatever it's named) in Word 2003.