guitardave78
Programmer
Is it possible to insert html formatted text into a bookmark using vba?
}...the bane of my life!
}...the bane of my life!
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Dim woobj As Word.Application
Set woobj = CreateObject("Word.Application")
With woobj
.Visible = True
.Documents.Open ("filename")
.Selection.GoTo What:=wdGoToBookmark, Name:="bookmarkname"
.ActiveDocument.Hyperlinks.Add Anchor:=.Selection.Range, Address:="[URL unfurl="true"]http://www.tek-tips.com/threadminder.cfm?pid=707",[/URL] TextToDisplay:="This tektip page"
End With
ActiveDocument.Bookmarks("here").Range _
.PasteSpecial DataType:=wdPasteHTML
These are not connected.The html code is passed to the application as a string yes.
So the clipboard has html tags in it.