Table of Contents

Method ToggleExpanded

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

ToggleExpanded(TreeViewItem?)

Toggles the expanded or collapsed state of the specified tree control item.

public virtual bool ToggleExpanded(TreeViewItem? item)

Parameters

item TreeViewItem

The TreeViewItem to toggle. If null or not a valid tree item, no action is taken.

Returns

bool

Remarks

If the specified item has child items, this method switches its state between expanded and collapsed. It does not affect the state of child items.