How to Remove Multiple Hyperlinks in MS Word
If the hyperlinks are the only fields in the document, or if you don't care
about the other fields, you can do it in the GUI with two keystrokes.
Ctrl+A -- Select all
Ctrl+Shift+F9 -- Unlink fields
This converts all fields to plain text of their displayed results.
If there are other fields that need to remain as fields, use this macro to
unlink only the hyperlinks:
Sub UnlinkHyperlinks()
Dim nHL As Long
For nHL = 1 To ActiveDocument.Hyperlinks.Count
ActiveDocument.Hyperlinks(1).Delete
Next nHL
End Sub
Two notes:
- The .Delete method in VBA does the same as Unlink in the GUI -- it will
leave the display text in place. To remove the entire thing, you need to do
.Hyperlinks(1).Range.Delete.
- As each hyperlink is deleted, the next one becomes .Hyperlinks(1). This
technique is needed because the Hyperlinks collection doesn't work properly
in a For Each loop in which the number of hyperlinks is being changed by
.Delete or .Add.