4

I am looking for an automated way to convert tracked changes in Microsoft Word 2010 to highlighted text. So, in essence what I'd like to do is:

  1. Highlight all text fragments with tracked changes
  2. Accept all tracked changes (there is a button for that)

Is there a way to do this either using built-in features or scripting?

5

There is the Revisions Object in VBA. From there it's simple to iterate through each revision item, accept and hightlight it with a predefined color.

Additionally we need to temporarly disable tracking.

Sub tracked_to_highlighted()           
    tempState = ActiveDocument.TrackRevisions
    ActiveDocument.TrackRevisions = False    
    For Each Change In ActiveDocument.Revisions        
        Set myRange = Change.Range
        myRange.Revisions.AcceptAll
        myRange.HighlightColorIndex = wdGreen            
    Next    
    ActiveDocument.TrackRevisions = tempState
End Sub
-2

Strange enough this does partly the job in my documents (Word 2010). The revisions are only highlighted from page 5. Haven't got a clue how to tell the macro to start from the top of the document, not even by

Selection.Homekey Unit:=wdStory

Manual accept every change does however consider the revisions on pages 1-4 as well.

Anybody similar experiences?

Peter

  • If you have a queston, you should one, questions should not appear in answers to other people's questions. – Ramhound Oct 31 '16 at 16:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.