FindItemData
Find the item with the given data.
int FindItemData( DWORD dwData )
Returns the index of item with the given data.
EX1
#include <..\OriginLab\DialogEx.h> #define IDC_COMBO1 1001 void ComboBox_FindItemData_ex1(Dialog& MyDlg) { ComboBox cmbBox = MyDlg.GetItem(IDC_COMBO1); if( cmbBox ) { DWORD dwData = 100; cmbBox.SetItemData(8, dwData); int nIndexFound = cmbBox.FindItemData(dwData); ASSERT(8 == nIndexFound); } }
Control.h