Saching22
June 4th, 2005, 10:32 AM
I am trying to add a second item to a ListView in VB from my win32 DLL, here is the code I wrote, please help me guys.
I provided my own entry point , and dont know how to allocate memory for this operation. I get a crash in vb when I use the dll
lvwLoghWnd is the handle to my listview in vb6,
LV_ITEM lv;
lv.pszText="DLL";
lv.iItem=1;
lv.iSubItem=0;
lv.cchTextMax=sizeof(LVITEM);
lv.iImage=0;
lv.mask = LVIF_TEXT;
SendMessage(lvwLoghWnd,LVM_INSERTITEM,0,(LPARAM)&lv);
I provided my own entry point , and dont know how to allocate memory for this operation. I get a crash in vb when I use the dll
lvwLoghWnd is the handle to my listview in vb6,
LV_ITEM lv;
lv.pszText="DLL";
lv.iItem=1;
lv.iSubItem=0;
lv.cchTextMax=sizeof(LVITEM);
lv.iImage=0;
lv.mask = LVIF_TEXT;
SendMessage(lvwLoghWnd,LVM_INSERTITEM,0,(LPARAM)&lv);