CB_GETCURSEL is alway returning zero although i have selected some nozero index... Why?
When i open it in debug mode and see value of 'sel' after this statement it is always zero ... why??? what could be wrong...
dlg->hHost is HWND to combo box.
Looks fine, are you sure that the HWND you pass is a valid value ?
iIndex = SendDlgItemMessage(hDialog , IDC_COMBO, CB_GETCURSEL, (WPARAM)0, (LPARAM) 0); //use the ID# and the parents HWND