View Single Post
 
Old 08-30-2020, 09:29 AM
alex100 alex100 is offline Windows 7 64bit Office 2016
Advanced Beginner
 
Join Date: May 2020
Posts: 79
alex100 is on a distinguished road
Default Find and replace all the text flagged with the 'wdDeletedTextMarkStrikeThrough' property

Is there a way to search and replace all the text that's flagged with the 'wdDeletedTextMarkStrikeThrough' property?

I tried the code below, but it doesn't work...

Code:
  With ActiveDocument.Content.Find
    .ClearFormatting
    .Font.DeletedTextMark = wdDeletedTextMarkStrikeThrough
    With .Replacement
        .ClearFormatting
        .Font.ColorIndex = wdRed
    End With
    .Execute FindText:="", ReplaceWith:="", Format:=True, Replace:=wdReplaceAll
  End With
Once it has been marked in red, I'd like to reject all the document revisions, so that the text will not get deleted. The following code line seems to work fine:

Code:
     ActiveDocument.RejectAllRevisions
Thank you!

Alex
Reply With Quote