Upravit

Sdílet prostřednictvím


DELETEITEMSTRUCT structure (winuser.h)

Describes a deleted list box or combo box item. The lParam parameter of a WM_DELETEITEM message contains a pointer to this structure. When an item is removed from a list box or combo box or when a list box or combo box is destroyed, the system sends the WM_DELETEITEM message to the owner for each deleted item.

The system sends a WM_DELETEITEM message only for items deleted from an owner-drawn list box (with the LBS_OWNERDRAWFIXED or LBS_OWNERDRAWVARIABLE style) or owner-drawn combo box (with the CBS_OWNERDRAWFIXED or CBS_OWNERDRAWVARIABLE style).

Syntax

typedef struct tagDELETEITEMSTRUCT {
  UINT      CtlType;
  UINT      CtlID;
  UINT      itemID;
  HWND      hwndItem;
  ULONG_PTR itemData;
} DELETEITEMSTRUCT, *PDELETEITEMSTRUCT, *LPDELETEITEMSTRUCT;

Members

CtlType

Type: UINT

Specifies whether the item was deleted from a list box or a combo box. One of the following values.

Value Meaning
ODT_LISTBOX
A list box.
ODT_COMBOBOX
A combo box.

CtlID

Type: UINT

The identifier of the list box or combo box.

itemID

Type: UINT

The index of the item in the list box or combo box being removed.

hwndItem

Type: HWND

A handle to the control.

itemData

Type: ULONG_PTR

Application-defined data for the item. This value is passed to the control in the lParam parameter of the message that adds the item to the list box or combo box.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header winuser.h (include Windows.h)

See also

WM_DELETEITEM