TX Text Control .NET for Windows Forms

DocumentLink Constructor

Constructor
Namespace
TXTextControl
Package
TXTextControl.TextControl.WinForms.SDK as TXTextControl.dll from the private NuGet feed or Text Control Offline Packages

Description

Initializes a new instance of the DocumentLink class.

Syntax

public DocumentLink(string text, DocumentTarget documentTarget);

Parameters

ParameterDescription
text

Specifies the visible text of the link.

documentTarget

Specifies an object of the type DocumentTarget specifying to where the link points.

Examples

The following example creates an internal link to the customer-details destination.

DocumentTarget target = new("CustomerDetails");
textControl.DocumentTargets.Add(target);
DocumentLink documentLink = new("View customer details", target);
textControl.DocumentLinks.Add(documentLink);