Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Yet Another Remove Hyperlink Question...
I have several Word macros that can and do delete all hyperlinks in any Word document. None provide what I am looking for. I need a Word macro that will delete all external hyperlinks leaving the text in place (but not preserving any underlines or coloring)... I also need to leave in place any hyperlinks that are internal (bookmark) hyperlinks. I want the macro to run without human intervention. No 'yes' or 'no' questions.
|
#2
Posted to microsoft.public.word.newusers
|
|||
|
|||
Yet Another Remove Hyperlink Question...
The following will delete hyperlinks, leaving the text in place without
underlines or colouring while preserving cross-references to bookmarks in the document. Dim i As Long, hrange As Range, htext As String With ActiveDocument For i = .Hyperlinks.Count To 1 Step -1 Set hrange = .Hyperlinks(i).Range htext = hrange.Text hrange.Delete hrange.InsertBefore htext Next i End With -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. Doug Robbins - Word MVP "wklind" wrote in message ... I have several Word macros that can and do delete all hyperlinks in any Word document. None provide what I am looking for. I need a Word macro that will delete all external hyperlinks leaving the text in place (but not preserving any underlines or coloring)... I also need to leave in place any hyperlinks that are internal (bookmark) hyperlinks. I want the macro to run without human intervention. No 'yes' or 'no' questions. -- wklind |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
hyperlink opens with wrong application | Microsoft Word Help | |||
Adding Hyperlink to documents > 100 pages - Headings Expanded Prob | Microsoft Word Help | |||
Hyperlink Hijinks | Microsoft Word Help | |||
Can more than one hyperlink at a time can be removed from a wo | Microsoft Word Help | |||
Hyperlink bug | Microsoft Word Help |