I use SetItemDataPtr to set listbox items pointers to my data, but i cannot get correct pointer when i call GetItemDataPtr?
For ex:
// Set data pointer when init listbox
m_lstBox.SetItemDataPtr(0, pointer); //pointer = 0x0123CDEF
…..
// In DrawItem()
pointer = GetItemDataPtr(lpDrawItemStruct->itemID); //lpDrawItemStruct->itemID = 0
// pointer != 0x0123CDEF
Why is that?
LR.
You inserted, removed, sorted or reordered the items.
Martyn