HeaderPane
Main
Hide
Share Link
Print

Click Event, SftTree Object

The selection changes.

Deprecated - Provided for compatibility with earlier versions only - Use the SelectionChange event instead

Syntax

C#void object_ClickEvent(object sender, EventArgumentType e);
VB.NETPrivate Sub object_ClickEvent(ByVal sender As Object, ByVal e As EventArgumentType) Handles object.ClickEvent
C++void OnClickobject();
CHRESULT OnClickobject();
VBPrivate Sub object_Click()

object

A SftTree object.

Comments

Deprecated - Provided for compatibility with earlier versions only - Use the SelectionChange event instead

The Click event occurs when the selection changes.

The Click event is not limited to mouse events as the selection can change through keyboard input also. To determine which mouse button was pressed and/or in which area of the tree control the mouse button was pressed, use the MouseDown or ItemClick events.

The Items.SelectionArea property can be used to control the areas that cause a selection change.

Examples

VB.NET View entire sample code

    Private Sub MenuExit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuExit.Click
        Application.Exit()
    End Sub

    Private Sub CopyImageFromCurrentItem()

        Dim ItemIndex As Integer
        Dim Img As SftPictureObject

        ItemIndex = AxSftTree1.Items.Current
        If ItemIndex < 0 Then Exit Sub

        ' don't use images that are too large in the other areas
        Img = AxSftTree1.get_Cell(ItemIndex, 0).Image
        If Img.ActualHeight <= 20 And Img.ActualWidth <= 20 Then
            AxSftTree1.RowColumnHeader.Image = Img

See Also SftTree Object | Object Hierarchy


Last Updated 11/03/2026 - (email)
© 2026 Softel vdm, Inc.