Click here to Skip to main content
15,892,005 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: std::vector gives linear memory - STL? Pin
Tomasz Sowinski22-Aug-02 23:54
Tomasz Sowinski22-Aug-02 23:54 
GeneralRe: std::vector gives linear memory - STL? Pin
markkuk23-Aug-02 2:14
markkuk23-Aug-02 2:14 
GeneralRe: thx Pin
Moak23-Aug-02 2:58
Moak23-Aug-02 2:58 
AnswerRe: std::vector gives linear memory - STL? Pin
Stuart Dootson23-Aug-02 8:42
professionalStuart Dootson23-Aug-02 8:42 
GeneralGeneral Question Pin
BK Pradeep22-Aug-02 23:34
BK Pradeep22-Aug-02 23:34 
GeneralRe: General Question Pin
pankajdaga22-Aug-02 23:43
pankajdaga22-Aug-02 23:43 
GeneralQuestion about BeginPaint and EndPaint Pin
pankajdaga22-Aug-02 22:32
pankajdaga22-Aug-02 22:32 
GeneralRe: Question about BeginPaint and EndPaint Pin
Paul M Watt22-Aug-02 22:41
mentorPaul M Watt22-Aug-02 22:41 
BeginPaint validates the update region for your window.

WM_PAINT messages are only generated when your message queue is empty, and your window has some portion of the window that is invalid. So if you call BeginPaint outside of the WM_PAINT handler, or ValidateRect(NULL) for that matter, you will be validating the entire window, and hence never receive a WM_PAINT message.

As long as you are not having any problems with the call to GetDC, you should continue to use that function. If you are experiencing problems, then you may want to work with the update region yourself, or invalidate portions of your window so that a WM_PAINT message is generated and you can handle the painting in your WM_PAINT handler.

Coincidentally, because the way that WM_PAINT messages are generated and the way that BeginPaint works, you should not generate WM_PAINT messages yourself, you should use RedrawWindow instead.

If you have any other questions don't hesitate to ask.

Good Luck



Build a man a fire, and he will be warm for a day
Light a man on fire, and he will be warm for the rest of his life!

GeneralRe: Question about BeginPaint and EndPaint Pin
Tomasz Sowinski22-Aug-02 22:42
Tomasz Sowinski22-Aug-02 22:42 
GeneralRe: Question about BeginPaint and EndPaint Pin
Paul M Watt22-Aug-02 22:52
mentorPaul M Watt22-Aug-02 22:52 
GeneralRe: Question about BeginPaint and EndPaint Pin
pankajdaga22-Aug-02 23:31
pankajdaga22-Aug-02 23:31 
GeneralCFlatTabCtrl Pin
alex.barylski22-Aug-02 21:57
alex.barylski22-Aug-02 21:57 
GeneralOverlapped sockets question Pin
Niko Tanghe22-Aug-02 21:50
Niko Tanghe22-Aug-02 21:50 
GeneralRe: Overlapped sockets question Pin
Moak23-Aug-02 3:14
Moak23-Aug-02 3:14 
QuestionWhere did my WM_COMMAND go? Pin
JennyP22-Aug-02 20:10
JennyP22-Aug-02 20:10 
AnswerRe: Where did my WM_COMMAND go? Pin
Tomasz Sowinski22-Aug-02 22:13
Tomasz Sowinski22-Aug-02 22:13 
GeneralRe: Where did my WM_COMMAND go? Pin
JennyP23-Aug-02 5:26
JennyP23-Aug-02 5:26 
GeneralRe: Where did my WM_COMMAND go? Pin
Tomasz Sowinski23-Aug-02 5:26
Tomasz Sowinski23-Aug-02 5:26 
GeneralRe: Where did my WM_COMMAND go? Pin
JennyP23-Aug-02 5:43
JennyP23-Aug-02 5:43 
GeneralRe: Where did my WM_COMMAND go? Pin
Tomasz Sowinski23-Aug-02 5:47
Tomasz Sowinski23-Aug-02 5:47 
QuestionCan I play MP3 from memory using DirectShow? Pin
sonshiro22-Aug-02 19:42
sonshiro22-Aug-02 19:42 
GeneralSlow metafiles on W2K Pin
Anonymous22-Aug-02 19:20
Anonymous22-Aug-02 19:20 
GeneralUpdating NT Log thru VC appl. Pin
abhinarulkar22-Aug-02 19:05
abhinarulkar22-Aug-02 19:05 
GeneralRe: Updating NT Log thru VC appl. Pin
Pavel Klocek22-Aug-02 22:42
Pavel Klocek22-Aug-02 22:42 
GeneralApplication Instance Pin
Prateeti22-Aug-02 18:57
Prateeti22-Aug-02 18:57 

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.