Click or drag to resize

HyperLink Class (Typed)

X#
Create a HyperLink control.
Inheritance Hierarchy
Object
  VObject
    Control
      TextControl
        FixedText
          HyperLink

Namespace:  XSharp.VO.SDK
Assembly:  XSharp.VOGUIClasses (in XSharp.VOGUIClasses.dll) Version: 2.24 GA
Syntax
[TypesChangedAttribute]
 CLASS HyperLink INHERIT FixedText
Request Example View Source

The HyperLink type exposes the following members.

Constructors
  NameDescription
Public methodHyperLink
Construct a HyperLink control.
Top
Functions
  NameDescription
Public methodOpenLink
Is the method that is invoked whenever the mouse is clicked over the HyperLink control.
Top
Remarks
The intention of this class is that the text would appear as a HyperLink to a www address or as an @ email address and therefore the cursor will appear as the normal hand. When the control is clicked on, it will attempt to "open" the text of the control using the OpenLink callback method. If the text is a www address it will open the default browser and attempt to navigate to the address. If the text contains an @ it will be taken as an email address and open the default email client.
Tip Tip
The difference between the HyperLink and the SysLink classes is in the way that the text is used. In a HyperLink control, ALL of the text is passed as the hyperlink where as in the SysLink control you can mix display text and hyperlink text. Also, in the HyperLink control, ALL of the displayed text is passed through to the ShellExecute method and you must make sure that there is nothing in it which could cause this to fail.
Examples
X#
1oFont1 := Font{,8,"Microsoft Sans Serif"}
2oFont1:Underline := TRUE
3oHL1 := HyperLink{ SELF, -1, Point{190, 25 }, ;
4Dimension{0, 0 }, "http://www.grafxsoft.com" }
5oHL1:font := oFont1
6oHL1:size := Dimension{150,20}
7oHL1:textcolor := Color{ COLORBLUE }
8oHL1:font:underline := TRUE
9oHL1:Show( )
See Also