-
August 29th, 2012, 07:38 PM
#1
[RESOLVED] ComboBox contains only one string!
Code:
case WM_SHOWWINDOW:
{HWND cbox = GetDlgItem(hDlg, IDC_COMBO1);
int cnt = GetPortsCount();
for (int i= 0; i<cnt; i++)
{
SendMessage(cbox, CB_ADDSTRING, 0, reinterpret_cast<LPARAM>((LPCTSTR) GetPort(i)));
}
break;}
cnt = 3, but combobox contains only one string. How correctly make it? I also test "0" to "i" - the same effect. I viewed this in one example.
-
August 30th, 2012, 02:59 AM
#2
Re: ComboBox contains only one string!
How did you detect that combobox contains only one string? Did you use CB_GETCOUNT message?
Victor Nijegorodov
-
August 30th, 2012, 08:39 AM
#3
Re: ComboBox contains only one string!
VictorN, it was small sorry really now all work.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|