Reply
 
Thread Tools Display Modes
  #1   Report Post  
Scott Cooper
 
Posts: n/a
Default Auto Updating TOC in Protected Form

I know this has been posted a few times but I thought I'd check to see
if anyone has come up with a viable solution or alternative yet.

Basically, I have a document with a standardized cover page,
information page, TOC, and procedures for performing a task. The cover
page is a protected section with form fields that allow users to update
basic information a/b the document (i.e. revision history, ect). The
rest of the document is broken into various protected and unprotected
sections, based on what I want the user to be able to modify.

Preferably, I want to be able to automatically update the TOC when the
document is saved, opened, or some other routine operation. Having to
manually update it is fine too. Just as some others in the newsgroup
have done, I have made the section that contains the TOC unprotected
but still can't update it when the document is locked.

The only solution I have seen posted is to use a macro to unprotect the
document, update the TOC, and re-protect the document. This is not a
viable solution for me b/c it erases the information that I want to
preserve in the form fields like my revision history, etc.

The only thing I can think of is maybe using a macro as described but
adding a step to convert the text in the form fields to regular text in
the document before re-protecting it.

Does anyone know how to do this? or has anyone come up with a
solution?

Thanks,

Scott

  #2   Report Post  
Jay Freedman
 
Posts: n/a
Default

Hi Scott,

There is no substitute for a macro that unprotects the document, does
the update, and reprotects. However, you don't need to convert
anything to regular text. As explained at
http://www.word.mvps.org/FAQs/Macros...lfResetOff.htm, the
Protect method in VBA has an optional NoReset parameter that prevents
it from clearing fields that already have values.

ActiveDocument.Protect Type:=wdAllowOnlyFormFields, NoReset:=True

There is no equivalent of this parameter when you use the menu and
dialogs, and that means it will never appear in purely recorded macros
either.

--
Regards,
Jay Freedman
Microsoft Word MVP FAQ: http://word.mvps.org

On 8 Jan 2005 07:50:08 -0800, "Scott Cooper"
wrote:

I know this has been posted a few times but I thought I'd check to see
if anyone has come up with a viable solution or alternative yet.

Basically, I have a document with a standardized cover page,
information page, TOC, and procedures for performing a task. The cover
page is a protected section with form fields that allow users to update
basic information a/b the document (i.e. revision history, ect). The
rest of the document is broken into various protected and unprotected
sections, based on what I want the user to be able to modify.

Preferably, I want to be able to automatically update the TOC when the
document is saved, opened, or some other routine operation. Having to
manually update it is fine too. Just as some others in the newsgroup
have done, I have made the section that contains the TOC unprotected
but still can't update it when the document is locked.

The only solution I have seen posted is to use a macro to unprotect the
document, update the TOC, and re-protect the document. This is not a
viable solution for me b/c it erases the information that I want to
preserve in the form fields like my revision history, etc.

The only thing I can think of is maybe using a macro as described but
adding a step to convert the text in the form fields to regular text in
the document before re-protecting it.

Does anyone know how to do this? or has anyone come up with a
solution?

Thanks,

Scott


  #3   Report Post  
Scott Cooper
 
Posts: n/a
Default

Thank you much!

I never caught onto the fact that the fields are not errased when using
the button on the Forms toolbar. This will suffice for me but it
doesn't seem that using the button allows me to re-password protect the
document. Am I missing something?

Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening a document in a protected form CheeryNan Microsoft Word Help 5 August 1st 22 07:34 AM
Protecting section of form while using Auto TOC elsewhere. AW Microsoft Word Help 4 January 19th 05 09:03 AM
Protected form spell check Mark Morrell Microsoft Word Help 3 January 5th 05 07:40 PM
Retain editable images and allow text boxes in a form PW protected Shannon Microsoft Word Help 2 December 8th 04 03:37 PM
Text boxes in protected Doc, form fields BP522 Microsoft Word Help 5 December 3rd 04 07:55 PM


All times are GMT +1. The time now is 11:17 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"