Click here to Skip to main content
15,895,084 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralWhy whould this be lost?... Pin
CherezZaboro18-Mar-03 12:29
CherezZaboro18-Mar-03 12:29 
GeneralRe: Why whould this be lost?... Pin
Dave Bryant18-Mar-03 12:44
Dave Bryant18-Mar-03 12:44 
GeneralRe: Why whould this be lost?... Pin
CherezZaboro18-Mar-03 12:56
CherezZaboro18-Mar-03 12:56 
GeneralRe: Why whould this be lost?... Pin
Dave Bryant18-Mar-03 13:00
Dave Bryant18-Mar-03 13:00 
GeneralRe: Why whould this be lost?... Pin
CherezZaboro18-Mar-03 13:11
CherezZaboro18-Mar-03 13:11 
GeneralRe: Why whould this be lost?... Pin
Dave Bryant18-Mar-03 15:03
Dave Bryant18-Mar-03 15:03 
GeneralRe: Why whould this be lost?... Pin
CherezZaboro18-Mar-03 18:23
CherezZaboro18-Mar-03 18:23 
GeneralListView Colors..weird Pin
Bengi18-Mar-03 11:10
Bengi18-Mar-03 11:10 
Anyone knows a reason why this would not paint my items/sub items ?

case WM_NOTIFY:
{
    switch(LOWORD(wParam))
    {
         case IDC_LIST: 
         {
              if(((LPNMHDR)lParam)->code == NM_CUSTOMDRAW)
              {
                 NMLVCUSTOMDRAW *cdraw = (NMLVCUSTOMDRAW*)lParam;
                        
                 if (cdraw->nmcd.dwDrawStage == CDDS_PREPAINT)
                     return CDRF_NOTIFYITEMDRAW;

                 if (cdraw->nmcd.dwDrawStage == CDDS_ITEMPREPAINT || cdraw->nmcd.dwDrawStage == CDDS_SUBITEM)
                 {      
                    COLORREF crText;
                            
                     if ( cdraw->iSubItem==2 )
                          crText = RGB(255,0,0);
                     else if ( cdraw->iSubItem==1 )
                          crText = RGB(0,255,0);
                     else
                          crText = RGB(128,128,255);
                            
                     cdraw->clrText = crText;
                            
                     return CDRF_DODEFAULT;
                 }
                        
              }
	}
    }	
}



the message never arrives at if (cdraw->nmcd.dwDrawStage == CDDS_ITEMPREPAINT || cdraw->nmcd.dwDrawStage == CDDS_SUBITEM)

i have seen other src codes and it all works well there (MFC examples but not API)

any brief idea?

/- Bengi - \
GeneralRe: ListView Colors..weird Pin
Bengi18-Mar-03 23:18
Bengi18-Mar-03 23:18 
GeneralRe: ListView Colors..weird Pin
Alexinuk18-Mar-03 23:23
Alexinuk18-Mar-03 23:23 
GeneralCButton and DialogBar Pin
MemLeak18-Mar-03 10:48
MemLeak18-Mar-03 10:48 
GeneralRe: CButton and DialogBar Pin
Ravi Bhavnani18-Mar-03 10:54
professionalRavi Bhavnani18-Mar-03 10:54 
GeneralRe: CButton and DialogBar Pin
MemLeak19-Mar-03 7:38
MemLeak19-Mar-03 7:38 
GeneralRe: CButton and DialogBar Pin
Ravi Bhavnani19-Mar-03 8:14
professionalRavi Bhavnani19-Mar-03 8:14 
GeneralAviCap Questions Pin
User 1278218-Mar-03 10:13
User 1278218-Mar-03 10:13 
GeneralSAPI 5.1 and Win98... Pin
JoeSox18-Mar-03 9:42
JoeSox18-Mar-03 9:42 
GeneralRe: SAPI 5.1 and Win98... Pin
Tim Smith18-Mar-03 9:54
Tim Smith18-Mar-03 9:54 
GeneralRe: SAPI 5.1 and Win98... Pin
JoeSox19-Mar-03 9:43
JoeSox19-Mar-03 9:43 
GeneralVery interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 9:36
Joel Holdsworth18-Mar-03 9:36 
GeneralRe: Very interesting Question about Compilers Pin
Chris Losinger18-Mar-03 10:31
professionalChris Losinger18-Mar-03 10:31 
GeneralRe: Very interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 10:45
Joel Holdsworth18-Mar-03 10:45 
GeneralRe: Very interesting Question about Compilers Pin
Neville Franks18-Mar-03 10:55
Neville Franks18-Mar-03 10:55 
GeneralRe: Very interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 11:26
Joel Holdsworth18-Mar-03 11:26 
GeneralRe: Very interesting Question about Compilers Pin
Neville Franks18-Mar-03 12:29
Neville Franks18-Mar-03 12:29 
GeneralON_THREAD_MESSAGE Pin
clintsinger18-Mar-03 9:20
clintsinger18-Mar-03 9:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.