Export (0) Print
Expand All
6 out of 13 rated this helpful - Rate this topic

Tree View

This section contains information about the programming elements used with tree-view controls.

Overviews

TopicContents
About Tree-View Controls

A tree-view control is a window that displays a hierarchical list of items, such as the headings in a document, the entries in an index, or the files and directories on a disk.

Using Tree-View Controls

This section contains implementation details and example code for working with tree-view controls.

 

Macros

TopicContents
TreeView_CreateDragImage

Creates a dragging bitmap for the specified item in a tree-view control. The macro also creates an image list for the bitmap and adds the bitmap to the image list. An application can display the image when dragging the item by using the image list functions. You can use this macro or send the TVM_CREATEDRAGIMAGE message explicitly.

TreeView_DeleteAllItems

Deletes all items from a tree-view control.

TreeView_DeleteItem

Removes an item and all its descendants from a tree-view control. You can also send the TVM_DELETEITEM message explicitly.

TreeView_EditLabel

Begins in-place editing of the specified item's text, replacing the text of the item with a single-line edit control containing the text. This macro implicitly selects and focuses the specified item. You can use this macro or send the TVM_EDITLABEL message explicitly.

TreeView_EndEditLabelNow

Ends the editing of a tree-view item's label. You can use this macro or send the TVM_ENDEDITLABELNOW message explicitly.

TreeView_EnsureVisible

Ensures that a tree-view item is visible, expanding the parent item or scrolling the tree-view control, if necessary. You can use this macro or send the TVM_ENSUREVISIBLE message explicitly.

TreeView_Expand

The TreeView_Expand macro expands or collapses the list of child items associated with the specified parent item, if any. You can use this macro or send the TVM_EXPAND message explicitly.

TreeView_GetBkColor

Retrieves the current background color of the control. You can use this macro or send the TVM_GETBKCOLOR message explicitly.

TreeView_GetCheckState

Gets the check state of the specified item. You can also use the TVM_GETITEMSTATE message directly.

TreeView_GetChild

Retrieves the first child item of the specified tree-view item. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_CHILD flag.

TreeView_GetCount

Retrieves a count of the items in a tree-view control. You can use this macro or send the TVM_GETCOUNT message explicitly.

TreeView_GetDropHilight

Retrieves the tree-view item that is the target of a drag-and-drop operation. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_DROPHILITE flag.

TreeView_GetEditControl

Retrieves the handle to the edit control being used to edit a tree-view item's text. You can use this macro or send the TVM_GETEDITCONTROL message explicitly.

TreeView_GetExtendedStyle

Retrieves the extended style for a specified tree-view control. Use this macro or send the TVM_GETEXTENDEDSTYLE message explicitly.

TreeView_GetFirstVisible

Retrieves the first visible item in a tree-view control window. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_FIRSTVISIBLE flag.

TreeView_GetImageList

Retrieves the handle to the normal or state image list associated with a tree-view control. You can use this macro or send the TVM_GETIMAGELIST message explicitly.

TreeView_GetIndent

Retrieves the amount, in pixels, that child items are indented relative to their parent items. You can use this macro or send the TVM_GETINDENT message explicitly.

TreeView_GetInsertMarkColor

Retrieves the color used to draw the insertion mark for the tree view. You can use this macro or send the TVM_GETINSERTMARKCOLOR message explicitly.

TreeView_GetISearchString

Retrieves the incremental search string for a tree-view control. The tree-view control uses the incremental search string to select an item based on characters typed by the user. You can use this macro or send the TVM_GETISEARCHSTRING message explicitly.

TreeView_GetItem

Retrieves some or all of a tree-view item's attributes. You can use this macro or send the TVM_GETITEM message explicitly.

TreeView_GetItemHeight

Retrieves the current height of the tree-view items. You can use this macro or send the TVM_GETITEMHEIGHT message explicitly.

TreeView_GetItemPartRect

Retrieves the largest possible bounding rectangle that constitutes the "hit zone" for a specified part of an item. Use this macro or send the TVM_GETITEMPARTRECT message explicitly.

TreeView_GetItemRect

Retrieves the bounding rectangle for a tree-view item and indicates whether the item is visible. You can use this macro or send the TVM_GETITEMRECT message explicitly.

TreeView_GetItemState

Retrieves some or all of a tree-view item's state attributes. You can use this macro or send the TVM_GETITEMSTATE message explicitly.

TreeView_GetLastVisible

Retrieves the last expanded item in a tree-view control. This does not retrieve the last item visible in the tree-view window. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_LASTVISIBLE flag.

TreeView_GetLineColor

Gets the current line color. You can also use the TVM_GETLINECOLOR message directly.

TreeView_GetNextItem

Retrieves the tree-view item that bears the specified relationship to a specified item. You can use this macro, use one of the TreeView_Get macros described below, or send the TVM_GETNEXTITEM message explicitly.

TreeView_GetNextSelected

Retrieves the tree-view item that bears the TVGN_NEXTSELECTED relationship to a specified tree item.

TreeView_GetNextSibling

Retrieves the next sibling item of a specified item in a tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_NEXT flag.

TreeView_GetNextVisible

Retrieves the next visible item that follows a specified item in a tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_NEXTVISIBLE flag.

TreeView_GetParent

Retrieves the parent item of the specified tree-view item. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_PARENT flag.

TreeView_GetPrevSibling

Retrieves the previous sibling item of a specified item in a tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_PREVIOUS flag.

TreeView_GetPrevVisible

Retrieves the first visible item that precedes a specified item in a tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_PREVIOUSVISIBLE flag.

TreeView_GetRoot

Retrieves the topmost or very first item of the tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_ROOT flag.

TreeView_GetScrollTime

Retrieves the maximum scroll time for the tree-view control. You can use this macro or send the TVM_GETSCROLLTIME message explicitly.

TreeView_GetSelectedCount

Not implemented.

TreeView_GetSelection

Retrieves the currently selected item in a tree-view control. You can use this macro, or you can explicitly send the TVM_GETNEXTITEM message with the TVGN_CARET flag.

TreeView_GetTextColor

Retrieves the current text color of the control. You can use this macro or send the TVM_GETTEXTCOLOR message explicitly.

TreeView_GetToolTips

Retrieves the handle to the child tooltip control used by a tree-view control. You can use this macro or send the TVM_GETTOOLTIPS message explicitly.

TreeView_GetUnicodeFormat

Retrieves the Unicode character format flag for the control. You can use this macro or send the TVM_GETUNICODEFORMAT message explicitly.

TreeView_GetVisibleCount

Obtains the number of items that can be fully visible in the client window of a tree-view control. You can use this macro or send the TVM_GETVISIBLECOUNT message explicitly.

TreeView_HitTest

Determines the location of the specified point relative to the client area of a tree-view control. You can use this macro or send the TVM_HITTEST message explicitly.

TreeView_InsertItem

Inserts a new item in a tree-view control. You can use this macro or send the TVM_INSERTITEM message explicitly.

TreeView_MapAccIDToHTREEITEM

Maps an accessibility ID to an HTREEITEM. You can use this macro or send the TVM_MAPACCIDTOHTREEITEM message explicitly.

TreeView_MapHTREEITEMtoAccID

Maps an HTREEITEM to an accessibility ID. You can use this macro or send the TVM_MAPHTREEITEMTOACCID message explicitly.

TreeView_Select

Selects the specified tree-view item, scrolls the item into view, or redraws the item in the style used to indicate the target of a drag-and-drop operation. You can use this macro or the TreeView_SelectItem, TreeView_SelectSetFirstVisible, or TreeView_SelectDropTarget macros, or you can send the TVM_SELECTITEM message explicitly.

TreeView_SelectDropTarget

Redraws a specified tree-view control item in the style used to indicate the target of a drag-and-drop operation. You can use this macro or the TreeView_Select macro, or you can send the TVM_SELECTITEM message explicitly.

TreeView_SelectItem

Selects the specified tree-view item. You can use this macro or the TreeView_Select macro, or you can send the TVM_SELECTITEM message explicitly.

TreeView_SelectSetFirstVisible

Scrolls the tree-view control vertically to ensure that the specified item is visible. If possible, the specified item becomes the first visible item at the top of the control's window. You can use this macro or the TreeView_Select macro, or you can send the TVM_SELECTITEM message explicitly.

TreeView_SetAutoScrollInfo

Sets information used to determine auto-scroll characteristics. Use this macro or send the TVM_SETAUTOSCROLLINFO message explicitly.

TreeView_SetBkColor

Sets the background color of the control. You can use this macro or send the TVM_SETBKCOLOR message explicitly.

TreeView_SetBorder

Intended for internal use; not recommended for use in applications.

Sets the size of the border for the items in a tree-view control. You can use this macro or send the TVM_SETBORDER message explicitly.

TreeView_SetCheckState

Sets the item's state image to "checked" or "unchecked." You can also use the TVM_SETITEM message directly.

TreeView_SetExtendedStyle

Sets the extended style for a specified TreeView control. Use this macro or send the TVM_SETEXTENDEDSTYLE message explicitly.

TreeView_SetHot

Intended for internal use; not recommended for use in applications.

Sets the hot item for a tree-view control. You can use this macro or send the TVM_SETHOT message explicitly.

TreeView_SetImageList

Sets the normal or state image list for a tree-view control and redraws the control using the new images. You can use this macro or send the TVM_SETIMAGELIST message explicitly.

TreeView_SetIndent

Sets the width of indentation for a tree-view control and redraws the control to reflect the new width. You can use this macro or send the TVM_SETINDENT message explicitly.

TreeView_SetInsertMark

Sets the insertion mark in a tree-view control. You can use this macro or send the TVM_SETINSERTMARK message explicitly.

TreeView_SetInsertMarkColor

Sets the color used to draw the insertion mark for the tree view. You can use this macro or send the TVM_SETINSERTMARKCOLOR message explicitly.

TreeView_SetItem

The TreeView_SetItem macro sets some or all of a tree-view item's attributes. You can use this macro or send the TVM_SETITEM message explicitly.

TreeView_SetItemHeight

Sets the height of the tree-view items. You can use this macro or send the TVM_SETITEMHEIGHT message explicitly.

TreeView_SetItemState

Sets a tree-view item's state attributes. You can use this macro or send the TVM_SETITEM message explicitly.

TreeView_SetLineColor

Sets the current line color. You can also use the TVM_SETLINECOLOR message directly.

TreeView_SetScrollTime

Sets the maximum scroll time for the tree-view control. You can use this macro or send the TVM_SETSCROLLTIME message explicitly.

TreeView_SetTextColor

Sets the text color of the control. You can use this macro or send the TVM_SETTEXTCOLOR message explicitly.

TreeView_SetToolTips

Sets a tree-view control's child tooltip control. You can use this macro or send the TVM_SETTOOLTIPS message explicitly.

TreeView_SetUnicodeFormat

Sets the Unicode character format flag for the control. This message allows you to change the character set used by the control at run time rather than having to re-create the control. You can use this macro or send the TVM_SETUNICODEFORMAT message explicitly.

TreeView_ShowInfoTip

Shows the infotip for a specified item in a tree-view control. Use this macro or send the TVM_SHOWINFOTIP message explicitly.

TreeView_SortChildren

Sorts the child items of the specified parent item in a tree-view control. You can use this macro or send the TVM_SORTCHILDREN message explicitly.

TreeView_SortChildrenCB

Sorts tree-view items using an application-defined callback function that compares the items. You can use this macro or send the TVM_SORTCHILDRENCB message explicitly.

 

Messages

TopicContents
TVM_CREATEDRAGIMAGE

Creates a dragging bitmap for the specified item in a tree-view control. The message also creates an image list for the bitmap and adds the bitmap to the image list. An application can display the image when dragging the item by using the image list functions. You can send this message explicitly or by using the TreeView_CreateDragImage macro.

TVM_DELETEITEM

Removes an item and all its descendants from a tree-view control. You can send this message explicitly or by using the TreeView_DeleteItem macro.

TVM_EDITLABEL

Begins in-place editing of the specified item's text, replacing the text of the item with a single-line edit control containing the text. This message implicitly selects and focuses the specified item. You can send this message explicitly or by using the TreeView_EditLabel macro.

TVM_ENDEDITLABELNOW

Ends the editing of a tree-view item's label. You can send this message explicitly or by using the TreeView_EndEditLabelNow macro.

TVM_ENSUREVISIBLE

Ensures that a tree-view item is visible, expanding the parent item or scrolling the tree-view control, if necessary. You can send this message explicitly or by using the TreeView_EnsureVisible macro.

TVM_EXPAND

The TVM_EXPAND message expands or collapses the list of child items associated with the specified parent item, if any. You can send this message explicitly or by using the TreeView_Expand macro.

TVM_GETBKCOLOR

Retrieves the current background color of the control. You can send this message explicitly or by using the TreeView_GetBkColor macro.

TVM_GETCOUNT

Retrieves a count of the items in a tree-view control. You can send this message explicitly or by using the TreeView_GetCount macro.

TVM_GETEDITCONTROL

Retrieves the handle to the edit control being used to edit a tree-view item's text. You can send this message explicitly or by using the TreeView_GetEditControl macro.

TVM_GETEXTENDEDSTYLE

Retrieves the extended style for a tree-view control. Send this message explicitly or by using the TreeView_GetExtendedStyle macro.

TVM_GETIMAGELIST

Retrieves the handle to the normal or state image list associated with a tree-view control. You can send this message explicitly or by using the TreeView_GetImageList macro.

TVM_GETINDENT

Retrieves the amount, in pixels, that child items are indented relative to their parent items. You can send this message explicitly or by using the TreeView_GetIndent macro.

TVM_GETINSERTMARKCOLOR

Retrieves the color used to draw the insertion mark for the tree view. You can send this message explicitly or by using the TreeView_GetInsertMarkColor macro.

TVM_GETISEARCHSTRING

Retrieves the incremental search string for a tree-view control. The tree-view control uses the incremental search string to select an item based on characters typed by the user. You can send this message explicitly or by using the TreeView_GetISearchString macro.

TVM_GETITEM

Retrieves some or all of a tree-view item's attributes. You can send this message explicitly or by using the TreeView_GetItem macro.

TVM_GETITEMHEIGHT

Retrieves the current height of the each tree-view item. You can send this message explicitly or by using the TreeView_GetItemHeight macro.

TVM_GETITEMPARTRECT

Not implemented.

TVM_GETITEMRECT

Retrieves the bounding rectangle for a tree-view item and indicates whether the item is visible. You can send this message explicitly or by using the TreeView_GetItemRect macro.

TVM_GETITEMSTATE

Retrieves some or all of a tree-view item's state attributes. You can send this message explicitly or by using the TreeView_GetItemState macro.

TVM_GETLINECOLOR

The TVM_GETLINECOLOR message gets the current line color.

TVM_GETNEXTITEM

Retrieves the tree-view item that bears the specified relationship to a specified item. You can send this message explicitly, by using the TreeView_GetNextItem macro.

TVM_GETSCROLLTIME

Retrieves the maximum scroll time for the tree-view control. You can send this message explicitly or by using the TreeView_GetScrollTime macro.

TVM_GETSELECTEDCOUNT

Not implemented.

TVM_GETTEXTCOLOR

Retrieves the current text color of the control. You can send this message explicitly or by using the TreeView_GetTextColor macro.

TVM_GETTOOLTIPS

Retrieves the handle to the child tooltip control used by a tree-view control. You can send this message explicitly or by using the TreeView_GetToolTips macro.

TVM_GETUNICODEFORMAT

Retrieves the Unicode character format flag for the control. You can send this message explicitly or use the TreeView_GetUnicodeFormat macro.

TVM_GETVISIBLECOUNT

Obtains the number of items that can be fully visible in the client window of a tree-view control. You can send this message explicitly or by using the TreeView_GetVisibleCount macro.

TVM_HITTEST

Determines the location of the specified point relative to the client area of a tree-view control. You can send this message explicitly or by using the TreeView_HitTest macro.

TVM_INSERTITEM

Inserts a new item in a tree-view control. You can send this message explicitly or by using the TreeView_InsertItem macro.

TVM_MAPACCIDTOHTREEITEM

Maps an accessibility ID to an HTREEITEM.

TVM_MAPHTREEITEMTOACCID

Maps an HTREEITEM to an accessibility ID.

TVM_SELECTITEM

Selects the specified tree-view item, scrolls the item into view, or redraws the item in the style used to indicate the target of a drag-and-drop operation. You can send this message explicitly or by using the TreeView_Select, TreeView_SelectItem, or TreeView_SelectDropTarget macro.

TVM_SETAUTOSCROLLINFO

Sets information used to determine auto-scroll characteristics. You can send this message explicitly or by using the TreeView_SetAutoScrollInfo macro.

TVM_SETBKCOLOR

Sets the background color of the control. You can send this message explicitly or by using the TreeView_SetBkColor macro.

TVM_SETBORDER

Intended for internal use; not recommended for use in applications.

Sets the size of the border for the items in a tree-view control. You can send the message explicitly or by using the TreeView_SetBorder macro.

TVM_SETEXTENDEDSTYLE

Informs the tree-view control to set extended styles. Send this message or use the macro TreeView_SetExtendedStyle.

TVM_SETHOT

Intended for internal use; not recommended for use in applications.

Sets the hot item for a tree-view control. You can send this message explicitly or by using the TreeView_SetHot macro.

TVM_SETIMAGELIST

Sets the normal or state image list for a tree-view control and redraws the control using the new images. You can send this message explicitly or by using the TreeView_SetImageList macro.

TVM_SETINDENT

Sets the width of indentation for a tree-view control and redraws the control to reflect the new width. You can send this message explicitly or by using the TreeView_SetIndent macro.

TVM_SETINSERTMARK

Sets the insertion mark in a tree-view control. You can send this message explicitly or by using the TreeView_SetInsertMark macro.

TVM_SETINSERTMARKCOLOR

Sets the color used to draw the insertion mark for the tree view. You can send this message explicitly or by using the TreeView_SetInsertMarkColor macro.

TVM_SETITEM

The TVM_SETITEM message sets some or all of a tree-view item's attributes. You can send this message explicitly or by using the TreeView_SetItem macro.

TVM_SETITEMHEIGHT

Sets the height of the tree-view items. You can send this message explicitly or by using the TreeView_SetItemHeight macro.

TVM_SETLINECOLOR

The TVM_SETLINECOLOR message sets the current line color.

TVM_SETSCROLLTIME

Sets the maximum scroll time for the tree-view control. You can send this message explicitly or by using the TreeView_SetScrollTime macro.

TVM_SETTEXTCOLOR

Sets the text color of the control. You can send this message explicitly or by using the TreeView_SetTextColor macro.

TVM_SETTOOLTIPS

Sets a tree-view control's child tooltip control. You can send this message explicitly or by using the TreeView_SetToolTips macro.

TVM_SETUNICODEFORMAT

Sets the Unicode character format flag for the control. This message allows you to change the character set used by the control at run time rather than having to re-create the control. You can send this message explicitly or use the TreeView_SetUnicodeFormat macro.

TVM_SHOWINFOTIP

Shows the infotip for a specified item in a tree-view control. You can send this message explicitly or by using the TreeView_ShowInfoTip macro..

TVM_SORTCHILDREN

Sorts the child items of the specified parent item in a tree-view control. You can send this message explicitly or by using the TreeView_SortChildren macro.

TVM_SORTCHILDRENCB

Sorts tree-view items using an application-defined callback function that compares the items. You can send this message explicitly or by using the TreeView_SortChildrenCB macro.

 

Notifications

TopicContents
NM_CLICK (tree view)

Notifies the parent window of a tree-view control that the user has clicked the left mouse button within the control. This notification is sent in the form of a WM_NOTIFY message.

NM_CUSTOMDRAW (tree view)

Sent by a tree-view control to notify its parent window about drawing operations. This notification is sent in the form of a WM_NOTIFY message.

NM_DBLCLK (tree view)

Notifies the parent window of a tree-view control that the user has double-clicked the left mouse button within the control. This notification is sent in the form of a WM_NOTIFY message.

NM_KILLFOCUS (tree view)

Notifies a tree-view control's parent window that the control has lost the input focus. This notification is sent in the form of a WM_NOTIFY message.

NM_RCLICK (tree view)

Notifies the parent window of a tree-view control that the user has clicked the right mouse button within the control. This notification is sent in the form of a WM_NOTIFY message.

NM_RDBLCLK (tree view)

Notifies the parent of a tree-view control that the user has double-clicked the right mouse button within the control. This notification is sent in the form of a WM_NOTIFY message.

NM_RETURN (tree view)

Notifies a tree-view control's parent window that the control has the input focus and that the user has pressed the key. This notification is sent in the form of a WM_NOTIFY message.

NM_SETCURSOR (tree view)

Notifies a tree-view control's parent window that the control is setting the cursor in response to a WM_SETCURSOR message. This notification is sent in the form of a WM_NOTIFY message.

NM_SETFOCUS (tree view)

Notifies a tree-view control's parent window that the control has received the input focus. This notification is sent in the form of a WM_NOTIFY message.

TVN_ASYNCDRAW

Sent by a tree-view control to its parent when the drawing of a icon or overlay has failed. This notification code is sent in the form of a WM_NOTIFY message.

TVN_BEGINDRAG

Notifies a tree-view control's parent window that a drag-and-drop operation involving the left mouse button is being initiated. This notification code is sent in the form of a WM_NOTIFY message.

TVN_BEGINLABELEDIT

Notifies a tree-view control's parent window about the start of label editing for an item. This notification code is sent in the form of a WM_NOTIFY message.

TVN_BEGINRDRAG

Notifies a tree-view control's parent window about the initiation of a drag-and-drop operation involving the right mouse button. This notification code is sent in the form of a WM_NOTIFY message.

TVN_DELETEITEM

Notifies a tree-view control's parent window that an item is being deleted. This notification code is sent in the form of a WM_NOTIFY message.

TVN_ENDLABELEDIT

Notifies a tree-view control's parent window about the end of label editing for an item. This notification code is sent in the form of a WM_NOTIFY message.

TVN_GETDISPINFO

Requests that a tree-view control's parent window provide information needed to display or sort an item. This notification code is sent in the form of a WM_NOTIFY message.

TVN_GETINFOTIP

Sent by a tree-view control that has the TVS_INFOTIP style. This notification is sent when the control is requesting additional text information to be displayed in a tooltip. The notification is sent in the form of a WM_NOTIFY message.

TVN_ITEMCHANGED

Notifies a tree-view control's parent window that item attributes have changed. This notification code is sent in the form of a WM_NOTIFY message.

TVN_ITEMCHANGING

Notifies a tree-view control's parent window that item attributes are about to change. This notification code is sent in the form of a WM_NOTIFY message.

TVN_ITEMEXPANDED

Notifies a tree-view control's parent window that a parent item's list of child items has expanded or collapsed. This notification code is sent in the form of a WM_NOTIFY message.

TVN_ITEMEXPANDING

Notifies a tree-view control's parent window that a parent item's list of child items is about to expand or collapse. This notification code is sent in the form of a WM_NOTIFY message.

TVN_KEYDOWN

Notifies a tree-view control's parent window that the user pressed a key and the tree-view control has the input focus. This notification code is sent in the form of a WM_NOTIFY message.

TVN_SELCHANGED

Notifies a tree-view control's parent window that the selection has changed from one item to another. This notification code is sent in the form of a WM_NOTIFY message.

TVN_SELCHANGING

Notifies a tree-view control's parent window that the selection is about to change from one item to another. This notification code is sent in the form of a WM_NOTIFY message.

TVN_SETDISPINFO

Notifies a tree-view control's parent window that it must update the information it maintains about an item. This notification code is sent in the form of a WM_NOTIFY message.

TVN_SINGLEEXPAND

Sent by a tree-view control with the TVS_SINGLEEXPAND style when the user opens or closes a tree item using a single click of the mouse. This notification is sent in the form of a WM_NOTIFY message.

 

Structures

TopicContents
NMTREEVIEW

Contains information about a tree-view notification code. This structure is identical to the NM_TREEVIEW structure, but it has been renamed to follow current naming conventions.

NMTVASYNCDRAW

Contains an explanation of why the draw of an icon or overlay tree item failed. This structure is sent on a TVN_ASYNCDRAW notification. Set the dwRetFlags member to indicate what action the control should take. Note that a draw can fail if there is no image; in other words, when the icon image has not been extracted.

NMTVCUSTOMDRAW

Contains information specific to an NM_CUSTOMDRAW (tree view) notification code sent by a tree-view control.

NMTVDISPINFO

Contains and receives display information for a tree-view item. This structure is identical to the TV_DISPINFO structure, but it has been renamed to follow current naming conventions.

NMTVDISPINFOEX

Contains information pertaining to extended TreeView notification information.

NMTVGETINFOTIP

Contains and receives tree-view item information needed to display a tooltip for an item. This structure is used with the TVN_GETINFOTIP notification code.

NMTVITEMCHANGE

Contains information on a tree-view item change. This structure is sent with the TVN_ITEMCHANGED and TVN_ITEMCHANGING notifications.

NMTVITEMRECT

Not currently supported.

NMTVKEYDOWN

Contains information about a keyboard event in a tree-view control. This structure is used with the TVN_KEYDOWN notification code. The structure is identical to the TV_KEYDOWN structure, but it has been renamed to follow current naming conventions.

NMTVSTATEIMAGECHANGING

Contains information about a tree-view state image changing notification code.

TVGETITEMPARTRECTINFO

Contains information for identifying the "hit zone" for a specified part of a tree item. The structure is used with the TVM_GETITEMPARTRECT message and the TreeView_GetItemPartRect macro.

TVHITTESTINFO

Contains information used to determine the location of a point relative to a tree-view control. This structure is used with the TVM_HITTEST message. The structure is identical to the TV_HITTESTINFO structure, but it has been renamed to follow current naming conventions.

TVINSERTSTRUCT

Contains information used to add a new item to a tree-view control. This structure is used with the TVM_INSERTITEM message. The structure is identical to the TV_INSERTSTRUCT structure, but it has been renamed to follow current naming conventions.

TVITEM

Specifies or receives attributes of a tree-view item. This structure is identical to the TV_ITEM structure, but it has been renamed to follow current naming conventions. New applications should use this structure.

TVITEMEX

Specifies or receives attributes of a tree-view item. This structure is an enhancement to the TVITEM structure. New applications should use this structure where appropriate.

TVSORTCB

Contains information used to sort child items in a tree-view control. This structure is used with the TVM_SORTCHILDRENCB message. This structure is identical to the TV_SORTCB structure, but it has been renamed to follow current naming conventions.

 

Constants

TopicContents
Tree-View Control Extended Styles

This section lists extended styles used when creating tree-view controls. The value of extended styles is a bitwise combination of these styles.

Tree-View Control Item States

This section lists the item state flags used to indicate the state of an item in a tree-view control.

Tree-View Control Window Styles

This section lists window styles used when creating tree-view controls.

 

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.