highlight all fields in Word

Discussion in 'Software' started by Raenty, May 17, 2017.

  1. Raenty

    Raenty

    Joined:
    May 17, 2017
    Messages:
    1
    Likes Received:
    0
    Hi,

    I want to highlight all the fields in my word document so that I can easily find them and edit them.

    Now I can only use Ctrl+A to select all and I will see that all fields have shading. But if I click in the document ,then they will disappear as I don't select all now.

    So I want to know if there is a way to always highlight all fields so that I can check them? Thanks.
     
    Raenty, May 17, 2017
    #1
    1. Advertisements

  2. Raenty

    Tadies

    Joined:
    May 20, 2017
    Messages:
    1
    Likes Received:
    0
    There are a lot of ways to do that. For example:

    1. Open "Word Options", and in "Advanced", set the“Field shading” option as “Always”.

    2. Use“Find”Function, just use “^d”to find all fields and choose to highlight them .

    3. Use VBA. Below is a macro I find.

    Code:
    Sub ShowFieldsInDoc()
      Dim objField As Field
      Dim objDoc As Document
      Dim strCodeText As String
      Set objDoc = ActiveDocument
      With objDoc
        For Each objField In .Fields
          If objField.Type = wdFieldRef Or wdFieldPageRef Then
            objField.Select
            Selection.Range.HighlightColorIndex = wdYellow
          End If
          If objField.Type = wdFieldHyperlink Then
            objField.Select
            Selection.Range.HighlightColorIndex = wdNoHighlight
          End If
        Next objField
      End With
    End Sub
    More details you can see at

    https://www.datanumen.com/blogs/3-quick-ways-find-fields-word-document/

    Hope it heps.
     
    Tadies, May 20, 2017
    #2
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. spike228

    can't highlight text with firefox

    spike228, Aug 19, 2005, in forum: Networking and Internet
    Replies:
    2
    Views:
    2,814
    spike228
    Aug 20, 2005
  2. S Walch

    Highlight table cells with a background Image

    S Walch, Apr 27, 2006, in forum: Web Design & Coding
    Replies:
    8
    Views:
    1,458
    S Walch
    Apr 27, 2006
  3. Adrian Kwa
    Replies:
    6
    Views:
    649
    Stevie Boy
    Feb 17, 2004
  4. John Phillips

    Hard drives and magnetic fields

    John Phillips, Nov 27, 2006, in forum: Computing
    Replies:
    5
    Views:
    845
    Rod Speed
    Nov 28, 2006
  5. |-|ercules
    Replies:
    0
    Views:
    520
    |-|ercules
    Sep 28, 2010
  6. Comptech

    SOLVED How To Highlight The 1St Row in A Listview VB.net

    Comptech, Dec 12, 2011, in forum: Web Design & Coding
    Replies:
    1
    Views:
    3,951
    AceInfinity
    Aug 13, 2012
  7. JF Mezei
    Replies:
    3
    Views:
    1,474
    Wes Groleau
    Mar 11, 2012
  8. JF Mezei

    Highlight colour on iPhone

    JF Mezei, Sep 23, 2014, in forum: iPhone
    Replies:
    1
    Views:
    296
    Your Name
    Sep 25, 2014
Loading...