event HyperLinkClick (Group as Group, Item as HITEM, ColIndex as Long)
Occurs when the user clicks on a hyperlink cell.

 TypeDescription 
   Group as Group A Group object where user clicks a hyper link cell.  
   Item as HITEM A long expression that indicates the item's handle.  
   ColIndex as Long A long expression that indicates the column's index.  
The HyperLinkClick event is fired when user clicks a hyperlink cell. A hyperlink cell has the CellHyperLink property true. Use the HyperLinkClick event to notify your application that a hyperlink cell is clicked. Use the HyperLinkColor property to specify the color of the hyper links items.

The following sample displays the caption of the clicked cell:

Private Sub ExplorerTree1_AddItem(ByVal Group As EXPLORERTREELibCtl.IGroup, ByVal Item As EXPLORERTREELibCtl.HITEM)
    Group.Items.CellHyperLink(Item, 0) = True
End Sub

Private Sub ExplorerTree1_HyperLinkClick(ByVal Group As EXPLORERTREELibCtl.IGroup, ByVal Item As EXPLORERTREELibCtl.HITEM, ByVal ColIndex As Long)
    Debug.Print Group.Items.CellCaption(Item, ColIndex)
End Sub

Private Sub Form_Load()
    With ExplorerTree1
        With .Groups.Add("Group 1")
            .SelForeColor = .HyperLinkColor
            .SelBackColor = .BackColorList
            .PutItems Array("http://www.exontrol.com", "http://www.exontrol.net")
        End With
    End With
End Sub


Send comments on this topic.
© 1999-2008 Exontrol Inc, Software. All rights reserved.