SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftTree/DLL 7.5 - Tree Control
SftBox/OCX 5.0 - Combo Box Control
SftButton/OCX 3.0 - Button Control
SftMask/OCX 7.0 - Masked Edit Control
SftTabs/OCX 6.5 - Tab Control (VB6 only)
SftTree/OCX 7.5 - Tree Control
SftTree/NET 2.0 - Tree Control
An item has been expanded.
| VB.NET | Private Sub object_ItemExpanded(ByVal sender As Object, ByVal e As EventArgumentType) Handles object.ItemExpanded |
| VB | Private Sub object_ItemExpanded(ByVal ItemIndex As Long) |
| C#.NET | void object_ItemExpanded(object sender, EventArgumentType e); |
| VC++ | void OnItemExpandedobject(long ItemIndex); |
| C | HRESULT OnItemExpandedobject(long ItemIndex); |
object
ItemIndex
The zero-based index of the item being expanded.
The ItemExpanded event occurs when an item has been expanded.
This is a notification only. No tree control items or cells should be manipulated while handling this event.
AxSftTree1.Items.Current = 0 ' select the first item
AxSftTree1.get_Item(0).Selected = True
AxSftTree1.Dock = DockStyle.Fill ' Maximize the main window
Me.WindowState = FormWindowState.Maximized
End Sub
Private Sub AxSftTree1_ItemExpanded(ByVal sender As System.Object, ByVal e As AxSftTreeLib80._DSftTreeEvents_ItemExpandedEvent) Handles AxSftTree1.ItemExpanded
If e.itemIndex = 2 Then
AxWindowsMediaPlayer1.Ctlcontrols.play()
End If
End Sub
Private Sub AxSftTree1_ItemCollapsed(ByVal sender As System.Object, ByVal e As AxSftTreeLib80._DSftTreeEvents_ItemCollapsedEvent) Handles AxSftTree1.ItemCollapsed
If e.itemIndex = 2 Then
void CContentWindowsDlg::OnItemDblClickSfttree1(long ItemIndex, short ColIndex, short AreaType, short Button, short Shift)
{
if (AreaType == constSftTreeColumnRes)
m_vTree->Column[ColIndex]->MakeOptimal();
}
BEGIN_EVENTSINK_MAP(CContentWindowsDlg, CDialog)
//{{AFX_EVENTSINK_MAP(CContentWindowsDlg)
ON_EVENT(CContentWindowsDlg, IDC_SFTTREE1, 42 /* ItemExpanded */, OnItemExpandedSfttree1, VTS_I4)
ON_EVENT(CContentWindowsDlg, IDC_SFTTREE1, 41 /* ItemCollapsed */, OnItemCollapsedSfttree1, VTS_I4)
ON_EVENT(CContentWindowsDlg, IDC_SFTTREE1, 5 /* ItemDblClick */, OnItemDblClickSfttree1, VTS_I4 VTS_I2 VTS_I2 VTS_I2 VTS_I2)
//}}AFX_EVENTSINK_MAP
END_EVENTSINK_MAP()
BOOL CContentWindowsDlg::OnWndMsg(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* pResult)
{See Also SftTree Object | Object Hierarchy
