Click here to Skip to main content
15,913,487 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: MDI/SDI Don't Fit...I need a Project-based Architecture Pin
Neville Franks21-Apr-03 12:08
Neville Franks21-Apr-03 12:08 
QuestionHow to Call a function from another class Pin
gmlnd21-Apr-03 7:44
gmlnd21-Apr-03 7:44 
AnswerRe: How to Call a function from another class Pin
David Crow21-Apr-03 7:47
David Crow21-Apr-03 7:47 
AnswerRe: How to Call a function from another class Pin
AnkushChopra21-Apr-03 19:10
AnkushChopra21-Apr-03 19:10 
GeneralRe: How to Call a function from another class Pin
gmlnd22-Apr-03 5:32
gmlnd22-Apr-03 5:32 
Generalhelp me@!Graphics and vectorgraph Pin
vagabond200221-Apr-03 7:16
vagabond200221-Apr-03 7:16 
GeneralRe: help me@!Graphics and vectorgraph Pin
John R. Shaw22-Apr-03 20:28
John R. Shaw22-Apr-03 20:28 
GeneralPeekMessage hanging Pin
Dave_21-Apr-03 6:57
Dave_21-Apr-03 6:57 
I have been using a modeless dialog for indicating the progress of a task. In the dialog is a CProgressCtrl, and a cancel button. I have recently added a CListCtrl as well.

Everything works fine as long as you do not move the dialog, or click in the list control. Once you do this, things start to get wierd. Usually, there is a 2-3 second delay when clicking on something, or moving the window. During this delay, nothing is happening with the task that the dialog is showing the progress of. It should be continuing on, but nothing happens. The screen does not draw correctly either.

Each time I manually break, the stack points to my function that is pumping messages (it gets called periodically during the task). The PeekMessage seems to be "stuck" for some reason. Again, this only happens if the dialog is moved, or when clicking on a control within the dialog.

Any ideas on why this may be happening? Any work-arounds?
<br />
while (::PeekMessage (&msg, NULL, 0,0, PM_NOREMOVE)) {<br />
    <br />
        if (pbrcv != NULL && msg.message == WM_MYMSG1){<br />
            *pbrcv = true;<br />
        }<br />
        if (!AfxGetApp()->PumpMessage()) {<br />
            ::PostQuitMessage(0);<br />
            return false;<br />
        }<br />
    }  <br />
    //<br />
    // Simulate the framework's idle processing mechanism.<br />
    //<br />
    LONG lIdle = 0;<br />
    while (AfxGetApp()->OnIdle (lIdle++))<br />
       ;<br />
}<br />


Thanks,

DaveQ
GeneralRe: PeekMessage hanging Pin
David Crow21-Apr-03 8:03
David Crow21-Apr-03 8:03 
GeneralRe: PeekMessage hanging Pin
Dave_21-Apr-03 9:32
Dave_21-Apr-03 9:32 
GeneralDeviceIoControl / GetOverlappedResult misbehaving Pin
Brian Tietz21-Apr-03 6:33
Brian Tietz21-Apr-03 6:33 
Generalwindows get bored me Pin
karanba21-Apr-03 6:01
karanba21-Apr-03 6:01 
GeneralRe: windows get bored me Pin
David Crow21-Apr-03 8:06
David Crow21-Apr-03 8:06 
Generaltem out for winsocks Pin
karanba21-Apr-03 5:50
karanba21-Apr-03 5:50 
GeneralRe: tem out for winsocks Pin
valikac21-Apr-03 9:45
valikac21-Apr-03 9:45 
GeneralLea Allocator.... Pin
User 988521-Apr-03 5:49
User 988521-Apr-03 5:49 
GeneralRe: Lea Allocator.... Pin
Tim Smith21-Apr-03 5:56
Tim Smith21-Apr-03 5:56 
GeneralRe: Lea Allocator.... Pin
User 988521-Apr-03 5:58
User 988521-Apr-03 5:58 
GeneralRe: Lea Allocator.... Pin
User 988521-Apr-03 5:57
User 988521-Apr-03 5:57 
QuestionShare memory problem? Pin
chen21-Apr-03 5:33
chen21-Apr-03 5:33 
AnswerRe: Share memory problem? Pin
John M. Drescher21-Apr-03 8:02
John M. Drescher21-Apr-03 8:02 
AnswerRe: Share memory problem? Pin
User 988521-Apr-03 9:36
User 988521-Apr-03 9:36 
QuestionHow to enumurate the shell folders like the explorer.exe? Pin
zmnie21-Apr-03 5:03
zmnie21-Apr-03 5:03 
Generaleasy question about RecordSet Pin
Martin_Viet21-Apr-03 4:33
Martin_Viet21-Apr-03 4:33 
GeneralRe: easy question about RecordSet Pin
dabs21-Apr-03 4:56
dabs21-Apr-03 4:56 

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.