small bug with List Control in vs 8
I'am using vs 8 beta 2. void
Today, i made a very simple program with List Control. I did like that:
1) From vs 8, create a MFC program for pocket pc 2003 based Dialog.
2) In Dialog, using toolbox to add List Control to Dialog.
3) Now, you can choose the List control, click right -mouse to go to
properties page.
4) In Properties pae, choose tag controls events, go to LVN_ITEMACTIVE
then, click Add <...>
5) Now, vs 8 will help you automaticly to create a WM_NOTIFY each times
you active an items.
6) But look carefully to source code vs created:
{
LPNMITEMACTIVATE pNMIA = reinterpret_cast<LPNMITEMACTIVATE>(pNMHDR);
TODO: Add your control notification handler code here*pResult = 0;
}
If you compile, you will meet an error withLPNMITEMACTIVATEcos it haven't been defined before. I tried to cast like that: With me, it work, i don't know if it makes some other bug or not. Can you please cheek it, experts?
So i look in the technical document,it say that we have to castpNMHDR to NMLISTVIEW, what do you think?
LPNMLISTVIEW pNMLV =reinterpret_cast<LPNMLISTVIEW>(pNMHDR);

