Advertisement
Guest User

Untitled

a guest
Aug 25th, 2016
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. cnt = 1
  2. Debug.Print "---------------------------------------"
  3. Debug.Print "NB rev= " & Format(ActiveDocument.Revisions.Count)
  4. On Error GoTo CONTINUER
  5. 'parcours
  6. For i = ActiveDocument.Revisions.Count To 1 Step -1
  7. Set rev = ActiveDocument.Revisions(i)
  8. f = IsObject(rev)
  9. Debug.Print f
  10. If Not (rev Is Nothing) Then
  11. Debug.Print "ty=" & rev.Type
  12. If rev.Type = wdRevisionDelete Then
  13. rev.Accept
  14. cnt = cnt + 1
  15. Debug.Print cnt
  16. End If
  17. If rev.FormatDescription <> "" Then
  18. rev.Accept
  19. cnt = cnt + 1
  20. Debug.Print cnt
  21. End If
  22. End If
  23. 'error
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement