A
Andrew
Hello,
I need to find a way to 'mark' text
I need to find a way to 'mark' text
I suppose you could add a unique string before and after the hyperlink e.g.
Dim oField As Range
For i = 1 To ActiveDocument.Fields.Count
ActiveDocument.Fields(i).Select
Set oField = Selection.Range
If ActiveDocument.Fields(i).Type = _
wdFieldHyperlink Then
oField.InsertBefore "&%&%&%"
oField.InsertAfter "&%&%&%"
End If
Next i
then remove it again from the other format.
--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP
My web sitewww.gmayor.com
Word MVP web sitehttp://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
The idea was that you removed the added strings once imported into the other
application. However, the following will put an image behind the field -
here I used a smiley from my hard drive You could create a small block of
colour or whatever as a graphic and replace the path in the code.
Dim oField As Range
For i = 1 To ActiveDocument.Fields.Count
ActiveDocument.Fields(i).Select
Set oField = Selection.Range
If ActiveDocument.Fields(i).Type = _
wdFieldHyperlink Then
With ActiveDocument.Shapes.AddPicture(Anchor:=oField, _
FileName:="D:\My Documents\My Pictures\AnimatedGIFs\smile.gif",
_
LinkToFile:=False, _
SaveWithDocument:=True)
.WrapFormat.Type = 3
.ZOrder 5
End With
End If
Next i
--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP
My web sitewww.gmayor.com
Word MVP web sitehttp://word.mvps.org
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
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.