Back to Devexpress

HyperlinkClickEventArgs.Link Property

windowsforms-devexpress-dot-utils-dot-hyperlinkclickeventargs.md

latest1.9 KB
Original Source

HyperlinkClickEventArgs.Link Property

Get or sets the URL of the clicked hyperlink.

Namespace : DevExpress.Utils

Assembly : DevExpress.Utils.v25.2.dll

NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core

Declaration

csharp
public string Link { get; set; }
vb
Public Property Link As String

Property Value

TypeDescription
String

The hyperlink value.

|

Remarks

The Link property allows you to replace the actual link value with a custom URL.

csharp
barStaticItem1.Caption = "Visit our <href=www.devexpress.com>Web-site</href>";

void OnHyperlinkClick(object sender, HyperlinkClickEventArgs e) {
    if (e.Link == "www.devexpress.com")
        e.Link = "https://www.devexpress.com/products/net/controls/winforms/";
    System.Diagnostics.Process.Start(e.Link);
}
vb
barStaticItem1.Caption = "Visit our <href=www.devexpress.com>Web-site</href>";

Private Sub OnHyperlinkClick(ByVal sender As Object, ByVal e As HyperlinkClickEventArgs)
    If e.Link = "www.devexpress.com" Then
        e.Link = "https://www.devexpress.com/products/net/controls/winforms/"
    End If
    System.Diagnostics.Process.Start(e.Link)
End Sub

See Also

HyperlinkClickEventArgs Class

HyperlinkClickEventArgs Members

DevExpress.Utils Namespace