Results 1 to 3 of 3
  1. #1
    New Lounger Bigshrimp60's Avatar
    Join Date
    Mar 2011
    Posts
    22
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Permanently shading fields in a template

    Hello Good People

    I have created a template that has a lot of shaded fields that are simply used as prompts to remind the user that something needs to be typed into those areas. Is there a way I can code the template so that the shading is always on only in this template and will disappear after the document has been completed? Some of the users don't like to have the field shaded option set to Always in Word Options because they have other documents in which they don't want to see the shaded fields. Thanks for any help and samples.

  2. #2
    Super Moderator
    Join Date
    Dec 2000
    Location
    New York, NY
    Posts
    2,970
    Thanks
    3
    Thanked 29 Times in 27 Posts
    Hi,

    Perhaps as a workaround you could try applying gray text highlighting to the fields, rather than turning on field shading. You could then use code to remove the text highlighting from all the fields, at the appropriate time.

    Gary

  3. #3
    Super Moderator
    Join Date
    Dec 2000
    Location
    New York, NY
    Posts
    2,970
    Thanks
    3
    Thanked 29 Times in 27 Posts
    Some code to remove text highlighting from all fields:
    Code:
    Dim aFld As Field
       For Each aFld In ActiveDocument.Fields
          aFld.Result.HighlightColorIndex = wdNoHighlight
       Next ' aFld
    Gary

Posting Permissions

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