Skip to content



Below is a list of the most important properties methods and events for TWebLinkLabel. TWebLinkLabel is similar to a VCL TLinkLabel.

For a sample TWebLinkLabel with caption set to:

This is a link to

the result is:

Designtime Runtime

HTML template tag

The HTML tag the component can be associated with in an HTML template. Assign the ID attribute with a unique value and set the identical value to the ElementID property. Detailed information can be found in the Use of HTML templates topic.

HTML tag <DIV ID=”UniqueID”></DIV>
ElementID UniqueID

Properties for TWebLinkLabel

Property Description
AutoSize Optionally sets the CSS classname for the label when styling via CSS is used
ElementClassName Optionally sets the CSS classname for the label when styling via CSS is used
ElementID Optionally sets the HTML element ID for a HTML element in the form HTML file the label needs to be connected with. When connected, no new label is created but the Delphi class is connected with the existing HTML element in the form HTML file
EllipsisPosition Sets the type of ellipsis to use for showing the text when it doesn't fit in the label rectangle.
epNone: no ellipsis used
epEndEllipsis: ellipsis at the end of the text
epPathEllipsis: label text contains a path name and ellipsis is set taking a file path in account
epWordEllipsis: ellipsis is positioned at word boundary
Layout Sets the vertical text position in the label
tlTop: top aligned
tlCenter: center aligned
tlBottom: bottom aligned
WordWrap When true, the text can be displayed wordwrapped in the label client rect

Events for TWebLinkLabel

Property Description
OnClick Triggered when the label is clicked
OnDblClick Triggered when the label is double-clicked
OnLinkClick Event triggered when a hyperlink in the TWebLinkLabel is clicked