TVM_GETITEM Message
TVM_GETITEM Message

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

To send this message, call the SendMessage function as follows.

Syntax

        lResult = SendMessage(     // returns LRESULT in lResult
        (HWND) hWndControl,        // handle to destination control
        (UINT) TVM_GETITEM,        // message ID
        (WPARAM) wParam,           // = 0; not used, must be zero
        (LPARAM) lParam            // = (LPARAM) (LPTVITEM) pitem
		
        - Version 4.71 and later -
		
        (WPARAM) wParam,           // = 0; not used, must be zero
        (LPARAM) lParam            // = (LPARAM) (LPTVITEMEX) pitem
        );
    

Parameters

wParam
Must be zero.
pitem
Pointer to a TVITEM structure that specifies the information to retrieve and receives information about the item. With version 4.71 and later, you can use a TVITEMEX structure instead.

Return Value

Remarks

When the message is sent, the hItem member of the TVITEM or TVITEMEX structure identifies the item to retrieve information about, and the mask member specifies the attributes to retrieve.

If the TVIF_TEXT flag is set in the mask member of the TVITEM or TVITEMEX structure, the pszText member must point to a valid buffer and the cchTextMax member must be set to the number of characters in that buffer.

Message Information

Headercommctrl.h
Minimum operating systems Windows NT 3.51, Windows 95
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
Page view tracker