Lock form

M

Margaret Upton

I have put a message on the Word new users site about being able to lock a
document. This is in Word 2007 where the ribbon does not have the option to
lock a form. You can unlock but not lock the form. I have tried to use the
Custom UI Editor and paste the XML script found on the Add Classic Form
Controls site without success. So I wondered if anybody could give me code
to put into a macro that would lock a form. I cannot see the point of
Microsoft giving you the option in Word 2007 to put in the form fields
because if you cannot lock the form it does not work. The company I work
for uses forms a lot and it is important that I can create, then lock a
form. Would be so grateful for some suggestions please.

Margaret
 
D

Doug Robbins - Word MVP

The facility to Protect a Document for Filling in Forms is under the Protect
Document section of the Developer Tab of the Ribbon.

Alternatively, (and easier to use) Customize the Quick Access toolbar by
adding the first Protect Document item that appears in the list of commands
when you display the commands from the All Commands category.

To use a macro to toggle the protection on and off, use:

With ActiveDocument
If .ProtectionType = wdNoProtection Then
.Protect wdAllowOnlyFormFields, NoReset
Else
.Unprotect
End If
End With


--
Hope this helps,

Doug Robbins - Word MVP

Please reply only to the newsgroups unless you wish to obtain my services on
a paid professional basis.
 
J

Jay Freedman

And even easier to use, customize the Quick Access Toolbar by adding
the Lock command. This is the same as the Lock icon on the Forms
toolbar in earlier versions. You need the Protect Document pane to set
up special conditions, such as protecting some but not all sections of
a multi-section document, but the Lock button suffices to just toggle
locking on and off.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top