Вниз
Скачать: CL | DM;

Добавление строк в COMBOBOEX   Найти похожие ветки 

 
Андрей Жук ©   (2005-06-06 17:24) [0]

Такой вот код
BOOL CALLBACK MyProcessEnumerator(DWORD dwPID, WORD wTask,
     LPCSTR szProcess, LPARAM lParam) {

 char ProcessName[80];
 
 COMBOBOXEXITEM cbei;  
 cbei.mask = CBEIF_TEXT;

if (wTask == 0)
     {
   
       wsprintf((LPTSTR) ProcessName,"%5u   %s\n", dwPID, szProcess);
cbei.iItem          = dwPID;
       cbei.pszText        = ProcessName;
       cbei.cchTextMax     = sizeof(ProcessName);
       SendMessage(hComboBox,CBEM_INSERTITEM,0,(LPARAM)&cbei);
     }
  return TRUE;
}

но он добавляет только 1 запись...


 
Игорь Шевченко ©   (2005-06-06 17:49) [1]

А TFM нынче не в почете ?

When the message is sent, the iItem member must be set to indicate the zero-based index at which to insert the item. To insert an item at the end of the list, set the iItem member to -1



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.45 MB
Время: 0.023 c
3-1119955483
Hohol
2005-06-28 14:44
2005.08.07
Обработка события onEditValueChanged в cxDBLookupComboBox


9-1113910376
[GameDev]
2005-04-19 15:32
2005.08.07
На какой ячейке мышь ?


1-1121630007
able
2005-07-17 23:53
2005.08.07
Перехват положения окна


8-1112617676
Kevin Brown
2005-04-04 16:27
2005.08.07
Конвертация из Gif в Bmp.


14-1121353595
Сибиряк
2005-07-14 19:06
2005.08.07
Портировать с РНР на Delphi.




   Наверх