Results 1 to 8 of 8
  1. #1
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    La Jolla, CA
    Posts
    1,470
    Thanks
    30
    Thanked 62 Times in 58 Posts

    Word 2010; updating fields in restricted access form

    Is it still the case that to update fields in a protected form in Word 2010 that you must have a macro written to un-protect, update, and then re-protect the document?

  2. #2
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    No, and it never has been, if your document uses formfields and 'filling in forms' protection.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  3. #3
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    La Jolla, CA
    Posts
    1,470
    Thanks
    30
    Thanked 62 Times in 58 Posts
    I guess I need some clarification. ASK fields will execute upon File --> New but not File --> Open. Is that right?
    For them to execute with File --> Open, I need an AutoOpen macro. Is that correct?

    I have two ASK fields and two related REF fields, but they don't automatically fire when I open either the template as new or open the file (if there's an AutoOpen in the file, they fire).

    This has never been intuitive for me ... after all these years!!

    Ideally, I'd like to be able to open the docx file and have the ASK fields prompt and then the REF fields fill in...without further intervention by the user.
    Last edited by kweaver; 2015-07-02 at 18:06.

  4. #4
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    For ASK fields, yes, but their behaviour in that regard has nothing to do with forms protection. Even if the field is in a protected part of the document, though, you don't need to go down the unprotect/reprotect route to update the bookmark used by the ASK field.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  5. #5
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    La Jolla, CA
    Posts
    1,470
    Thanks
    30
    Thanked 62 Times in 58 Posts
    Ideally, I'd like to be able to open the docx file and have the ASK fields prompt and then the REF fields fill in...without further intervention by the user.

    This doesn't happen unless I do an F9 after a CTRL-A.

    How do I make it automatically ASK?

  6. #6
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    You could use a Document_Open macro in either the document itself or in its template, coded as:
    Code:
    Private Sub Document_Open()
    ActiveDocument.Fields.Update
    End Sub
    to trigger the ASK field, but that isn't going to cause any cross-references to update when you fill it in. You could re-execute the ActiveDocument.Fields.Update line to do that, but then the ASK field will prompt a second time. It's possible to prevent the second triggering with some additional field coding, but then it won't trigger next time you open the document, either...
    Cheers,

    Paul Edstein
    [MS MVP - Word]

  7. #7
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    La Jolla, CA
    Posts
    1,470
    Thanks
    30
    Thanked 62 Times in 58 Posts
    Yes, that's what I mentioned initially. I need an AutoOpen macro to accomplish this. That's a pain. Oh well.

  8. #8
    Super Moderator
    Join Date
    May 2002
    Location
    Canberra, Australian Capital Territory, Australia
    Posts
    5,054
    Thanks
    2
    Thanked 417 Times in 346 Posts
    Quote Originally Posted by kweaver View Post
    Yes, that's what I mentioned initially.
    Well, your first post mentioned "updating fields in restricted access form", but that has nothing to do with ASK fields, which you didn't mention, or with getting them to prompt when opening an existing document. It's not clear even now whether forms protection has any role in what you're doing.
    Cheers,

    Paul Edstein
    [MS MVP - Word]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •