View Single Post
 
Old 08-31-2020, 01:23 AM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,161
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

Looping from the start can be bad if you are changing the number of revisions inside your loop. You should start from the back if that is the case. If rejecting the revision is problematic, maybe make sure you aren't revision tracking the font formatting steps.
Code:
Sub ManualRevisions()
  Dim iRev As Long
  ActiveDocument.TrackRevisions = False
  For iRev = ActiveDocument.Revisions.Count To 1 Step -1
    With ActiveDocument.Revisions(iRev)
      Select Case .Type
        Case wdRevisionDelete, wdRevisionCellDeletion    '2 & 17
          .Range.Font.ColorIndex = wdRed
          .Range.Font.Shading.BackgroundPatternColor = RGB(222, 222, 222)
          .Reject
      End Select
    End With
  Next iRev
End Sub
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote