Control Reference > VSPrinter Control > VSPrinter Methods > AddLinkTarget Method |
Adds a Target tag (%PDFName|<name>) to the document at the cursor position.
AddLinkTarget(TargetText As String, TargetName As String)
TargetText is the text that will be displayed in the document.
TargetName is the name of the target which can be reached by clicking on hyperlinks that reference it.
Hyperlinks that point to local references should precede the target name with a pound sign "#". The target name itself should not include the pound sign. For example:
vp.AddLinkTarget "Home"
GenerateDocumentContent vp ' << your routine
vp.AddLink "Go back home", "#Home", True
Note: Internally, link targets are represented as custom tags with the following format: "%PDFName|<linkTarget>". If you want, you can create link targets using the StartTag and EndTag methods to add tags using the specified format. |