Microsoft Word - How To Get A List Of All Hyperlinked Files?

I

ikovy

I'm trying to get a list of all the files a Microsoft Word document is
hyperlinked to. Is there a way to have Word generate or show a list of all
the files a Word document is hyperlinked to?

Thanks
 
J

Jay Freedman

I'm trying to get a list of all the files a Microsoft Word document is
hyperlinked to. Is there a way to have Word generate or show a list of all
the files a Word document is hyperlinked to?

Thanks

Use this macro (see http://www.gmayor.com/installing_macro.htm if
needed):

Sub ListHyperlinks()
Dim srcDoc As Document, destDoc As Document
Dim HL As Hyperlink

Set srcDoc = ActiveDocument
Set destDoc = Documents.Add

For Each HL In srcDoc.Hyperlinks
destDoc.Range.InsertAfter _
HL.TextToDisplay & vbTab & HL.Address & vbCr
Next

destDoc.Range.ConvertToTable
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top