🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #39

Re: Some HDC questions

#39
From: Remy Lebeau (TeamB)
Date: Tue, 05 Aug 2008 20:49
21 lines
1630 bytes
"UO" <uo@uott> wrote in message news:4898a6fd$1@newsgroups.borland.com...

> Sorry, my mistake. The code should be:

Your code is still not looking at the wParam value.  And it is passing an 
invalid HWND to both BeginPaint() and EndPaint() as well.  Try this instead:

    case WM_PAINT:
        if( wParam == 0 )
            hdc = BeginPaint(hwnd, &ps);

        else
            hdc = reinterpret_cast<HDC>(wParam);
        ...
        if( wParam == 0 )
            EndPaint(hwnd, &ps);
        break;


Gambit 
Technical Details
Message-ID: <4898bd3c$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nac.net!feeder.erje.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <489877b5$1@newsgroups.borland.com> <489892df$1@newsgroups.borland.com> <4898a6fd$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,fa1b3304c969ec75
X-Google-Attributes: gid10cc67,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <489877b5$1@newsgroups.borland.com> <489892df$1@newsgroups.borland.com> <4898a6fd$1@newsgroups.borland.com>
Subject: Re: Some HDC questions
Date: Tue, 5 Aug 2008 13:49:22 -0700
Lines: 23
Organization: Lebeau Software
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3198
NNTP-Posting-Host: 207.178.157.90
Message-ID: <4898bd3c$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1217969468 207.178.157.90 (5 Aug 2008 13:51:08 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nac.net!feeder.erje.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
X-Original-Bytes: 1404