windowsforms-devexpress-dot-utils-dot-hyperlinkclickeventargs-5c6491d5.md
Gets or sets the hyperlink alt text. Note that modifying this text does not change the item caption.
Namespace : DevExpress.Utils
Assembly : DevExpress.Utils.v25.2.dll
NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core
public string Text { get; set; }
Public Property Text As String
| Type | Description |
|---|---|
| String |
The hyperlink alt text.
|
The sample below illustrates the difference between HyperlinkClickEventArgs.Text and BarItem.Caption properties.
counter = 0;
barStaticItem1.Caption = "<a href=fakeurl>Click to increase the counter (Current value: "
+ counter.ToString() + ")";
void OnHyperlinkClick(object sender, HyperlinkClickEventArgs e) {
if (e.Link == "fakeurl") {
counter++;
e.Text = "Click to increase the counter(Current value: " + counter.ToString() + ")";
barStaticItem1.Hint = "e.Text value: '" + e.Text + "'" ;
}
}
counter = 0
barStaticItem1.Caption = "<a href=fakeurl>Click to increase the counter (Current value: " & counter.ToString() & ")"
Private Sub OnHyperlinkClick(ByVal sender As Object, ByVal e As HyperlinkClickEventArgs)
If e.Link = "fakeurl" Then
counter += 1
e.Text = "Click to increase the counter(Current value: " & counter.ToString() & ")"
barStaticItem1.Hint = "e.Text value: '" & e.Text & "'"
End If
End Sub
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Text property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
create-winforms-accordion-control-in-code/CS/AccordionControl-ex/Form1.cs#L126
private void hyperlinkLabelControl1_HyperlinkClick(object sender, DevExpress.Utils.HyperlinkClickEventArgs e) {
Process.Start(e.Text);
}
create-winforms-accordion-control-in-code/VB/AccordionControl-ex/Form1.vb#L116
Private Sub hyperlinkLabelControl1_HyperlinkClick(ByVal sender As Object, ByVal e As DevExpress.Utils.HyperlinkClickEventArgs)
Call Process.Start(e.Text)
End Sub
See Also