I have a two page template in which the first page contains nothing but
tables and the second and every page there after contains a repeating header
and footer (but not shown on the first page). I have the concept of document
protection and have created a bookmark called bmDocNarrative and inserted it
on Page 2 where I want the user to start typing.

When the template is opened into a document, it is protected and the user
fills in the fields based on Form Fields. When the user tabs out of the last
form field on Page 1, there is an on exit macro which unprotects the document
and goes to the said bookmark so the user can start typing the narrative.

My question is if the user arrows or mouse clicks their way back to page
one, all of the tables are now â??unlockedâ?? because the document is
unprotected. What would some simple code be to force the document back into
protection mode while Page 1 is active and to unlock it if the user tries to
click back into the text (or page 2 or any other page than page 1)? Or am I
making this too complicated?

Re: Unprotecting and Protecting Document via mouse click on active pag by Jezebel

Jezebel
Thu Aug 10 16:35:39 CDT 2006

Put a section break between pages one and two, and protect only section one.



"Brendan" <Brendan@discussions.microsoft.com> wrote in message
news:861E41BA-4E7E-44F8-830B-7302885D69D0@microsoft.com...
> I have a two page template in which the first page contains nothing but
> tables and the second and every page there after contains a repeating
> header
> and footer (but not shown on the first page). I have the concept of
> document
> protection and have created a bookmark called bmDocNarrative and inserted
> it
> on Page 2 where I want the user to start typing.
>
> When the template is opened into a document, it is protected and the user
> fills in the fields based on Form Fields. When the user tabs out of the
> last
> form field on Page 1, there is an on exit macro which unprotects the
> document
> and goes to the said bookmark so the user can start typing the narrative.
>
> My question is if the user arrows or mouse clicks their way back to page
> one, all of the tables are now "unlocked" because the document is
> unprotected. What would some simple code be to force the document back
> into
> protection mode while Page 1 is active and to unlock it if the user tries
> to
> click back into the text (or page 2 or any other page than page 1)? Or am
> I
> making this too complicated?
>



Re: Unprotecting and Protecting Document via mouse click on active by Brendan

Brendan
Thu Aug 10 17:01:02 CDT 2006

I know the below code works for the entire document but what would the code
be for just the section?

ActiveDocument.Protect _
Type:=wdAllowOnlyFormFields, _
NoReset:=True, _
Password:=""




"Jezebel" wrote:

> Put a section break between pages one and two, and protect only section one.
>
>
>
> "Brendan" <Brendan@discussions.microsoft.com> wrote in message
> news:861E41BA-4E7E-44F8-830B-7302885D69D0@microsoft.com...
> > I have a two page template in which the first page contains nothing but
> > tables and the second and every page there after contains a repeating
> > header
> > and footer (but not shown on the first page). I have the concept of
> > document
> > protection and have created a bookmark called bmDocNarrative and inserted
> > it
> > on Page 2 where I want the user to start typing.
> >
> > When the template is opened into a document, it is protected and the user
> > fills in the fields based on Form Fields. When the user tabs out of the
> > last
> > form field on Page 1, there is an on exit macro which unprotects the
> > document
> > and goes to the said bookmark so the user can start typing the narrative.
> >
> > My question is if the user arrows or mouse clicks their way back to page
> > one, all of the tables are now "unlocked" because the document is
> > unprotected. What would some simple code be to force the document back
> > into
> > protection mode while Page 1 is active and to unlock it if the user tries
> > to
> > click back into the text (or page 2 or any other page than page 1)? Or am
> > I
> > making this too complicated?
> >
>
>
>

Re: Unprotecting and Protecting Document via mouse click on active by Jezebel

Jezebel
Thu Aug 10 17:37:16 CDT 2006

activedocument.sections(1).Protectedforforms = true



"Brendan" <Brendan@discussions.microsoft.com> wrote in message
news:A2E68393-742C-41FC-9275-FCCAF4C478B5@microsoft.com...
>I know the below code works for the entire document but what would the code
> be for just the section?
>
> ActiveDocument.Protect _
> Type:=wdAllowOnlyFormFields, _
> NoReset:=True, _
> Password:=""
>
>
>
>
> "Jezebel" wrote:
>
>> Put a section break between pages one and two, and protect only section
>> one.
>>
>>
>>
>> "Brendan" <Brendan@discussions.microsoft.com> wrote in message
>> news:861E41BA-4E7E-44F8-830B-7302885D69D0@microsoft.com...
>> > I have a two page template in which the first page contains nothing but
>> > tables and the second and every page there after contains a repeating
>> > header
>> > and footer (but not shown on the first page). I have the concept of
>> > document
>> > protection and have created a bookmark called bmDocNarrative and
>> > inserted
>> > it
>> > on Page 2 where I want the user to start typing.
>> >
>> > When the template is opened into a document, it is protected and the
>> > user
>> > fills in the fields based on Form Fields. When the user tabs out of
>> > the
>> > last
>> > form field on Page 1, there is an on exit macro which unprotects the
>> > document
>> > and goes to the said bookmark so the user can start typing the
>> > narrative.
>> >
>> > My question is if the user arrows or mouse clicks their way back to
>> > page
>> > one, all of the tables are now "unlocked" because the document is
>> > unprotected. What would some simple code be to force the document back
>> > into
>> > protection mode while Page 1 is active and to unlock it if the user
>> > tries
>> > to
>> > click back into the text (or page 2 or any other page than page 1)? Or
>> > am
>> > I
>> > making this too complicated?
>> >
>>
>>
>>



Re: Unprotecting and Protecting Document via mouse click on active by Jezebel

Jezebel
Thu Aug 10 17:36:53 CDT 2006


"Brendan" <Brendan@discussions.microsoft.com> wrote in message
news:A2E68393-742C-41FC-9275-FCCAF4C478B5@microsoft.com...
>I know the below code works for the entire document but what would the code
> be for just the section?
>
> ActiveDocument.Protect _
> Type:=wdAllowOnlyFormFields, _
> NoReset:=True, _
> Password:=""
>
>
>
>
> "Jezebel" wrote:
>
>> Put a section break between pages one and two, and protect only section
>> one.
>>
>>
>>
>> "Brendan" <Brendan@discussions.microsoft.com> wrote in message
>> news:861E41BA-4E7E-44F8-830B-7302885D69D0@microsoft.com...
>> > I have a two page template in which the first page contains nothing but
>> > tables and the second and every page there after contains a repeating
>> > header
>> > and footer (but not shown on the first page). I have the concept of
>> > document
>> > protection and have created a bookmark called bmDocNarrative and
>> > inserted
>> > it
>> > on Page 2 where I want the user to start typing.
>> >
>> > When the template is opened into a document, it is protected and the
>> > user
>> > fills in the fields based on Form Fields. When the user tabs out of
>> > the
>> > last
>> > form field on Page 1, there is an on exit macro which unprotects the
>> > document
>> > and goes to the said bookmark so the user can start typing the
>> > narrative.
>> >
>> > My question is if the user arrows or mouse clicks their way back to
>> > page
>> > one, all of the tables are now "unlocked" because the document is
>> > unprotected. What would some simple code be to force the document back
>> > into
>> > protection mode while Page 1 is active and to unlock it if the user
>> > tries
>> > to
>> > click back into the text (or page 2 or any other page than page 1)? Or
>> > am
>> > I
>> > making this too complicated?
>> >
>>
>>
>>



Re: Unprotecting and Protecting Document via mouse click on active by Jean-Guy

Jean-Guy
Fri Aug 11 09:06:32 CDT 2006

Brendan was telling us:
Brendan nous racontait que :

> I know the below code works for the entire document but what would
> the code be for just the section?
>
> ActiveDocument.Protect _
> Type:=wdAllowOnlyFormFields, _
> NoReset:=True, _
> Password:=""

As you wrote, this code will lock/unlock the whole document.

If you already tagged some sections to be protected, than only those
sections will be affected by the locking/unlocking.

So, when you create the template, manually assigned which sections need
protecting and which don't.
Then, in code, you can lock/unlock as you want, and only the concerned
sections will lock/unlock.

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
jmarcilREMOVE@CAPSsympatico.caTHISTOO
Word MVP site: http://www.word.mvps.org



Re: Unprotecting and Protecting Document via mouse click on active by Brendan

Brendan
Wed Aug 16 11:29:03 CDT 2006

The section break works fine but I cannot get from page 1 to page 2 via an on
exit macro from the last field. This macro goes to a bookmark for the
narrative. The macro tests fine when the section or document is not
protected but from within the protected section, it does not work. My Goal is
to have page 1 protected all the time with all other pages unprotected.

"Jezebel" wrote:

> activedocument.sections(1).Protectedforforms = true
>
>
>
> "Brendan" <Brendan@discussions.microsoft.com> wrote in message
> news:A2E68393-742C-41FC-9275-FCCAF4C478B5@microsoft.com...
> >I know the below code works for the entire document but what would the code
> > be for just the section?
> >
> > ActiveDocument.Protect _
> > Type:=wdAllowOnlyFormFields, _
> > NoReset:=True, _
> > Password:=""
> >
> >
> >
> >
> > "Jezebel" wrote:
> >
> >> Put a section break between pages one and two, and protect only section
> >> one.
> >>
> >>
> >>
> >> "Brendan" <Brendan@discussions.microsoft.com> wrote in message
> >> news:861E41BA-4E7E-44F8-830B-7302885D69D0@microsoft.com...
> >> > I have a two page template in which the first page contains nothing but
> >> > tables and the second and every page there after contains a repeating
> >> > header
> >> > and footer (but not shown on the first page). I have the concept of
> >> > document
> >> > protection and have created a bookmark called bmDocNarrative and
> >> > inserted
> >> > it
> >> > on Page 2 where I want the user to start typing.
> >> >
> >> > When the template is opened into a document, it is protected and the
> >> > user
> >> > fills in the fields based on Form Fields. When the user tabs out of
> >> > the
> >> > last
> >> > form field on Page 1, there is an on exit macro which unprotects the
> >> > document
> >> > and goes to the said bookmark so the user can start typing the
> >> > narrative.
> >> >
> >> > My question is if the user arrows or mouse clicks their way back to
> >> > page
> >> > one, all of the tables are now "unlocked" because the document is
> >> > unprotected. What would some simple code be to force the document back
> >> > into
> >> > protection mode while Page 1 is active and to unlock it if the user
> >> > tries
> >> > to
> >> > click back into the text (or page 2 or any other page than page 1)? Or
> >> > am
> >> > I
> >> > making this too complicated?
> >> >
> >>
> >>
> >>
>
>
>