Partager via


CB_GETITEMDATA

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This message is sent by an application to a combo box to retrieve the application-supplied 32-bit value associated with the specified item in the combo box.

Syntax

CB_GETITEMDATA wParam = (WPARAM) index; 
    lParam = 0;

Parameters

  • index
    Specifies the zero-based index of the item.
  • lParam
    Not used.

Return Value

The 32-bit value associated with the item indicates success. CB_ERR indicates that an error has occurred.

If the item is in an owner-drawn combo box created without the CBS_HASSTRINGS style, the return value is the 32-bit value contained in the lParam parameter of the CB_ADDSTRING or CB_INSERTSTRING message that added the item to the combo box. If the CBS_HASSTRINGS style was not used, the return value is the lParam parameter contained in a CB_SETITEMDATA message.

Requirements

Header winuser.h
Windows Embedded CE Windows CE 1.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

Combo Boxes Messages
SendMessage
CB_ADDSTRING
CB_INSERTSTRING
CB_SETITEMDATA