Вниз
Скачать: 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.025 c
3-1120217231
syte_ser78
2005-07-01 15:27
2005.08.07
БД в комбо


3-1119893189
Jungle Forever!
2005-06-27 21:26
2005.08.07
mysql group


10-1098782958
Sash
2004-10-26 13:29
2005.08.07
excel


14-1121309347
Магнум
2005-07-14 06:49
2005.08.07
Windows Media Player и WMV


3-1120213163
leonidus
2005-07-01 14:19
2005.08.07
ЧуднОй пример в Delphi 6 для работы с ADO




   Наверх