Hinweis
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, sich anzumelden oder das Verzeichnis zu wechseln.
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, das Verzeichnis zu wechseln.
intSetItemData(intnIndex**,DWORDdwItemData);**
Return Value
CB_ERR if an error occurs.
Parameters
nIndex
Contains a zero-based index to the item to set.
dwItemData
Contains the new value to associate with the item.
Remarks
Sets the 32-bit value associated with the specified item in a combo box. Use the SetItemDataPtr member function if the 32-bit item is to be a pointer.
Example
// The pointer to my combo box.
extern CComboBox* pmyComboBox;
// Set the data of each item to be equal to its index.
for (int i=0;i < pmyComboBox->GetCount();i++)
{
pmyComboBox->SetItemData(i, i);
}
CComboBox Overview | Class Members | Hierarchy Chart
See Also CComboBox::GetItemData, CComboBox::GetItemDataPtr, CComboBox::SetItemDataPtr, , CComboBox::AddString, CComboBox::InsertString