Table of Contents
TreeView Properties

The properties of the TreeView class are listed below. For a complete list of TreeView class members, see the TreeView Members topic.

Properties
Name Description
Adapter (inherited from Control) 
AllowDragDrop Gets or sets a value indicating whether user can use drag and drop to move a node.
AllowDragReordering Specifies whether user can use drag and drop to reordering nodes.
AllowEdit Gets or sets a value indicating whether user can edit the tree node text.
AllowMultiSelect Specifies whether multiple nodes can be selected.
AppRelativeTemplateSourceDirectory (inherited from Control) 
Attributes (inherited from WebControl) 
AutoCheckChildren Specifies if changing a TreeNode's CheckState property to Checked automatically changes all of its child nodes' CheckState property to Checked.
AutoCheckParent Specifies if change a TreeNode's CheckState automatically changes its parent node's CheckState.
AutoCollapseOnClick Specifies whether clicking an expanded TreeNode should automatically collapse the node or not.
AutoExpandOnClick Specifies whether clicking an collapsed TreeNode should automatically expand the node or not.
AutoScroll Specifies whether to apply scroll bars if a TreeView's content grows larger than the TreeView frame's dimension. Applying scroll bar will keep the TreeView dimension fixed.
AutoSelectSource (inherited from BaseNavigator) Specifies how navigation control automatically selects navigation items.
AutoSelectTarget (inherited from BaseNavigator) Specifies options on how to highlight a navigation item which points to currently browsing page.
AutoUncheckChildren Specifies if changing a TreeNode's CheckState property to Unchecked automatically changes all of its child nodes' CheckState property to Unchecked.
AutoWrap Gets or sets a value indicating whether tree node should occupy full-width and automatically wrap tree node text if necessary.
BackColor (inherited from BaseNavigator) Gets or sets background color of top level group.
Bindings (inherited from BaseNavigator) Gets a collection of bindings that map fields of the data source to the properties of the item.
BorderColor (inherited from BaseNavigator) Gets or sets border color of top level group.
BorderImages (inherited from WebControl) Provides a list of images used to create customized borders for the control.
BorderStyle (inherited from BaseNavigator) Gets or sets border style of top level group.
BorderWidth (inherited from BaseNavigator) Gets or sets border width of top level group.
CausesValidation (inherited from BaseNavigator) Gets or sets a boolean indicates if clicking an item causes validation to be performed on any controls that require validation.
CheckBoxImages Gets a TreeViewCheckBoxImages object that controls images to be displayed to indicate the CheckState of a tree node.
CheckIconUrl (inherited from BaseNavigator) Specifies the Url of the image used to be displayed on the left side of a navigation item when the item's Checked property is true.
ChildControlsCreated (inherited from Control) 
ClientID (inherited from Control) 
ClientIDMode (inherited from Control) 
ClientIDSeparator (inherited from Control) 
ClientSideAfterPopulate Gets or sets the name of the client side function to be called after populating on demand.
ClientSideOnCheckStateChanging Gets or sets the name of the client side function to be called when a node's check state is about to change.
ClientSideOnContextMenu Gets or sets the name of the client side function to be called to display a context menu when a node is right-clicked.
ClientSideOnDragBegin Gets or sets the name of the client side function to be called when user starts to drag a node.
ClientSideOnDragDrop Gets or sets the name of the client side function to be called when user drops a node on another node.
ClientSideOnDragOver Gets or sets the name of the client side function to be called when user drags a node over another node.
ClientSideOnError (inherited from WebControlBase) Gets or sets the name of the JavaScript function that is called when an error occurs on client side.
ClientSideOnEvalVar (inherited from WebControl) Specifies the name of client side JavaScript function which is called when a variable needs to be evaluated in a client template.
ClientSideOnGroupCollapsed (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when a navigation group has just collapsed.
ClientSideOnGroupExpand (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when a navigation group is about to expand.
ClientSideOnItemClick (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when a navigation item is clicked.
ClientSideOnItemMouseDown (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when user clicks the mouse on a navigation item.
ClientSideOnItemMouseOut (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when mouse leaves a navigation item.
ClientSideOnItemMouseOver (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when mouse moves over a navigation item.
ClientSideOnLoad (inherited from WebControlBase) Gets or sets the name of the JavaScript function that is called when the control is loaded on the client side.
ClientSideOnMessage (inherited from WebControlBase) Gets or sets the name of the JavaScript function that is called when the control displays a message.
ClientSideOnMouseOut (inherited from BaseNavigator) Specifies the name of the client side JavaScript function to be executed when the mouse cursor leaves the control.
ClientSideOnNodeRename Gets or sets the name of the client side function to be called after user has edited the tree node text.
ClientSideOnNodeRenaming Gets or sets the name of the client side function to be called when user is about to edit the tree node text.
ClientSideOnUnload (inherited from WebControlBase) Gets or sets the name of the JavaScript function that is called when the control is unloaded on the client side.
CollapsedNodeImageUrl Shortcut to Default look's CollapsedImageUrl property.
Context (inherited from Control) 
ContextNode Returns a TreeNode object that has displayed a context menu and subsequently the context menu triggered a server event.
Controls (inherited from Control) 
ControlSkinID (inherited from WebControl) Specifies the ID of the skin used by this control.
ControlStyle (inherited from WebControl) 
ControlStyleCreated (inherited from WebControl) 
CssBlock (inherited from WebControl) Specifies the CSS style definition used by this control.
CssClass (inherited from BaseNavigator) Gets or sets the CSS class name applied to top level group.
CssFile (inherited from WebControl) Specifies the path of an external CSS file that provides CSS styles used by this control.
DataFields (inherited from BaseNavigator) Specifies a list of fields used during data binding when binding to an ADO.NET data object. Use '|' to separate multiple fields.
DataItem (inherited from DataBoundControl) The current data item during data binding.
DataItemContainer (inherited from Control) 
DataKeysContainer (inherited from Control) 
DataSource (inherited from BaseNavigator) Gets or sets a data source used to populate navigation items.
DataSourceID (inherited from BaseNavigator) Gets or sets the ID of this control's data source object. Used in .NET 2.0 only.
DataTable (inherited from BaseNavigator) Gets or sets the name of the DataTable object when DataSource is a DataSet.
DesignMode (inherited from Control) 
DesignOptions (inherited from WebControl) Contains options used for design time preview.
DragDropScope Gets or sets the drag drop scope.
Enabled (inherited from WebControl) 
EnableKeyboardNavigation (inherited from WebControl) Gets or sets a value indicating whether keyboard navigation should be enabled.
EnableScrolling (inherited from BaseNavigator) Gets or sets the value indicating whether scrolling is enabled.
EnableTheming (inherited from WebControl) 
EnableViewState (inherited from Control) 
Events (inherited from Control) 
ExpandedNodeImageUrl Shortcut to Default look's ExpandedImageUrl property.
ForceSSL (inherited from WebControl) Gets or sets a value indicating whether the server should work as if it were always running on a secure server (https).
ForeColor (inherited from BaseNavigator) Gets or sets foreground color of top level group.
HasAttributes (inherited from WebControl) 
HasChildViewState (inherited from Control) 
Height Specifies the height of the TreeView.
HideRoleDisabledItems (inherited from BaseNavigator) Gets or sets a value indicating to hide or disable navigation items based on roles.
ID (inherited from Control) 
IdSeparator (inherited from Control) 
ImageBaseDirectory (inherited from WebControl) Gets or sets the folder that contains images for the control.
Indent Specifies a tree node's indent (in pixel) to its parent level nodes.
IsChildControlStateCleared (inherited from Control) 
IsEnabled (inherited from WebControl) 
IsTrackingViewState (inherited from Control) 
IsViewStateEnabled (inherited from Control) 
LineImages Gets a TreeViewLineImages object that controls images to be displayed on all level tree nodes' indent space.
LoadingLookID When a TreeNode's PopulateOnDemand is set to true, use this property to control the appearance when the TreeNode is being loaded.
LoadViewStateByID (inherited from Control) 
LookNodes Returns a collection of "Look" nodes.
Margin Gets a TreeViewMargin object that controls image to be displayed on the left margin of a TreeView.
MultiPageID (inherited from BaseNavigator) Gets or sets the ID of the associated MultiPage control.
NamingContainer (inherited from Control) 
NodeImageUrl Shortcut to Default look's ImageUrl property.
Nodes Represents a collection of TreeNodes.
Orientation (inherited from BaseNavigator) Gets or sets the orientation of top level group.
Parent (inherited from Control) 
PathSeparator (inherited from BaseNavigator) Gets or sets the character used to delimit the path of an item in a navigation control.
RaisesServerEvent (inherited from BaseNavigator) Gets or sets a boolean indicates if a server side postback ItemClick event should be raised when an item is clicked. Default value is false.
RenderingCompatibility (inherited from Control) 
RightToLeft (inherited from WebControl) Gets or sets a value indicating whether the control should renders as right to left.
SaveStateCrossPages (inherited from BaseNavigator) Gets or sets the value indicating whether control state should be saved across pages.
ScrollDownLookID (inherited from BaseNavigator) Gets or sets the look ID for down scroller.
ScrollSpeed (inherited from BaseNavigator) Specifies a scroll speed when scrolling is enabled.
ScrollUpLookID (inherited from BaseNavigator) Gets or sets the look ID for upper scroller.
SelectedNode Returns the current selected node.
SelectedNodes Returns all selected nodes.
Shortcut (inherited from WebControl) Get a Shortcut object through which you can get or set the keyboard short cut for this control.
SingleExpandMode Specifies the single expand mode.
Site (inherited from Control) 
SkinID (inherited from WebControl) 
StateCookieName (inherited from BaseNavigator) Gets or sets the name of the cookie that is used to save control state across pages.
Style (inherited from WebControl) 
SupportsDisabledAttribute (inherited from WebControl) 
TabIndex (inherited from WebControl) 
TagKey (inherited from WebControl) 
TagName (inherited from WebControl) 
TargetWindow (inherited from BaseNavigator) Gets or sets the target window to display NavigateUrl.
TemplateControl (inherited from Control) 
TemplateSourceDirectory (inherited from Control) 
TextBoxStyle Gets or sets style properties of the text box used to edit a tree node.
ToolTip (inherited from WebControl) 
TopGroup Gets the top level group.
TopLevelItemAlign (inherited from BaseNavigator) Gets or sets the value to specify how navigation items in top level horizontal group are aligned. Applies to navigation control that has horizontal style (e.g, a horizontal menu) only.
UniqueID (inherited from Control) 
ValidateRequestMode (inherited from Control) 
ViewState (inherited from Control) 
ViewStateIgnoresCase (inherited from Control) 
ViewStateMode (inherited from Control) 
Visible (inherited from Control) 
Width (inherited from WebControl) 
XmlFile (inherited from BaseNavigator) Used to support binding the control to XML data source on .NET 1.1.
See Also