Click here to Skip to main content
15,923,845 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRepaointing the Window Pin
BobInNJ26-Dec-08 12:37
BobInNJ26-Dec-08 12:37 
GeneralRe: Repaointing the Window Pin
Luc Pattyn26-Dec-08 13:20
sitebuilderLuc Pattyn26-Dec-08 13:20 
GeneralRe: Repainting the Window Pin
BobInNJ27-Dec-08 10:31
BobInNJ27-Dec-08 10:31 
GeneralRe: Repainting the Window Pin
Luc Pattyn27-Dec-08 11:30
sitebuilderLuc Pattyn27-Dec-08 11:30 
GeneralRe: Repainting the Window Pin
BobInNJ27-Dec-08 13:49
BobInNJ27-Dec-08 13:49 
GeneralRe: Repainting the Window Pin
Luc Pattyn27-Dec-08 15:15
sitebuilderLuc Pattyn27-Dec-08 15:15 
GeneralRe: Repainting the Window Pin
BobInNJ28-Dec-08 6:43
BobInNJ28-Dec-08 6:43 
GeneralRe: Repainting the Window Pin
Luc Pattyn28-Dec-08 14:15
sitebuilderLuc Pattyn28-Dec-08 14:15 
Hi Bob,

1.
I am not sure where you have put the Sleep stuff; if it is inside a handler (button click, paint,...)
then it won't help you, since that would cause the GUI thread to sleep, i.e. not do anything for
as long as it takes.

2.
many years ago screen coordinates were only 15 or 16 bits effectively (even when their variables could hold more); I don't know what GDI currently accepts. so a wild guess could be your big rect is invalid, InvalidateRect accepts or maybe rejects it (look at its return value!),
and somehow Windows decides there still is nothing to update due to the invalid rect parameters.
If you doubt your coordinates, just use 0 for top and left, 30000 for bottom and right.

BTW, you should always test the return values, and especially when your code does not do what you would like to get...

Smile | :)

Luc Pattyn [Forum Guidelines] [My Articles]

Fixturized forever. Confused | :confused:


GeneralRe: Repainting the Window Pin
BobInNJ29-Dec-08 6:58
BobInNJ29-Dec-08 6:58 
GeneralRe: Repainting the Window Pin
Luc Pattyn29-Dec-08 7:13
sitebuilderLuc Pattyn29-Dec-08 7:13 
GeneralRe: Repainting the Window Pin
BobInNJ29-Dec-08 9:08
BobInNJ29-Dec-08 9:08 
GeneralRe: Repainting the Window Pin
Luc Pattyn29-Dec-08 9:55
sitebuilderLuc Pattyn29-Dec-08 9:55 
GeneralRe: Repainting the Window Pin
BobInNJ29-Dec-08 11:28
BobInNJ29-Dec-08 11:28 
GeneralRe: Repainting the Window Pin
Luc Pattyn29-Dec-08 14:58
sitebuilderLuc Pattyn29-Dec-08 14:58 
GeneralRe: Repainting the Window Pin
BobInNJ30-Dec-08 4:37
BobInNJ30-Dec-08 4:37 
AnswerRe: Repainting the Window [modified] Pin
BobInNJ29-Dec-08 9:03
BobInNJ29-Dec-08 9:03 
Questioncan you help me a recursion project with c++? Pin
silversword8626-Dec-08 8:58
silversword8626-Dec-08 8:58 
GeneralRe: can you help me a recursion project with c++? Pin
Luc Pattyn26-Dec-08 9:20
sitebuilderLuc Pattyn26-Dec-08 9:20 
Questionhtml res files don't seem to work anymore. Pin
Jim Crafton26-Dec-08 4:55
Jim Crafton26-Dec-08 4:55 
AnswerRe: html res files don't seem to work anymore. Pin
Richard Andrew x6426-Dec-08 5:10
professionalRichard Andrew x6426-Dec-08 5:10 
GeneralRe: html res files don't seem to work anymore. Pin
Jim Crafton26-Dec-08 5:13
Jim Crafton26-Dec-08 5:13 
GeneralRe: html res files don't seem to work anymore. Pin
Richard Andrew x6426-Dec-08 5:15
professionalRichard Andrew x6426-Dec-08 5:15 
GeneralRe: html res files don't seem to work anymore. Pin
Jim Crafton26-Dec-08 5:27
Jim Crafton26-Dec-08 5:27 
GeneralRe: html res files don't seem to work anymore. Pin
Richard Andrew x6426-Dec-08 5:30
professionalRichard Andrew x6426-Dec-08 5:30 
GeneralRe: html res files don't seem to work anymore. Pin
Richard Andrew x6426-Dec-08 5:47
professionalRichard Andrew x6426-Dec-08 5:47 

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.