Click here to Skip to main content
15,925,133 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How is force DoEvents on priority. Pin
SandipG 6-Aug-08 22:33
SandipG 6-Aug-08 22:33 
GeneralRe: How is force DoEvents on priority. Pin
ptr_Electron6-Aug-08 22:45
ptr_Electron6-Aug-08 22:45 
GeneralRe: How is force DoEvents on priority. Pin
David Crow7-Aug-08 3:23
David Crow7-Aug-08 3:23 
GeneralRe: How is force DoEvents on priority. Pin
Stephen Hewitt6-Aug-08 22:19
Stephen Hewitt6-Aug-08 22:19 
GeneralRe: How is force DoEvents on priority. Pin
ptr_Electron7-Aug-08 0:10
ptr_Electron7-Aug-08 0:10 
GeneralRe: How is force DoEvents on priority. Pin
Stephen Hewitt7-Aug-08 14:43
Stephen Hewitt7-Aug-08 14:43 
GeneralRe: How is force DoEvents on priority. Pin
David Crow7-Aug-08 3:19
David Crow7-Aug-08 3:19 
GeneralRe: How is force DoEvents on priority. Pin
ptr_Electron7-Aug-08 21:54
ptr_Electron7-Aug-08 21:54 
Yes I removed sleep. I am using waitableTimmer to keep the UI active, during a very length call. Progress bar is working fine, but UI is Frised pls suggest me some good idea for this,

HANDLE timer = CreateWaitableTimer(0,false,0);
    LARGE_INTEGER li;
    const int unitsPerSecond=10*1000*1000; // 100 nano seconds
	li.QuadPart=-(2*unitsPerSecond);
    SetWaitableTimer(timer,&li,350,0,0,false);
   _beginthreadex(0,0,TF,(void*) timer,0,0); // call


unsigned __stdcall TF(void* arg) // def
 {
  HANDLE timer=(HANDLE) arg;

  while (1)
  {
	  if(iStoped==0)
		  return 0;
    WaitForSingleObject(timer,INFINITE);
	//PostMessage(hwnd1,WM_USER_THREAD_UPDATE_PROGRESS1, 0, 100);
	prgBar->StepIt(); // prg bar is progressing
        DoEvents(); // this is not working, UI is frized
  }

_endthread();
return 0;
}



void DoEvents() 
{
      MSG oMSG;
      while(::PeekMessage(&oMSG, NULL, 0, 0, PM_NOREMOVE))
      { 
                  ::TranslateMessage(&oMSG);
                  ::DispatchMessage(&oMSG);
       }
}

GeneralRe: How is force DoEvents on priority. Pin
David Crow8-Aug-08 3:18
David Crow8-Aug-08 3:18 
QuestionHDD image Pin
nutkase6-Aug-08 21:18
nutkase6-Aug-08 21:18 
AnswerRe: HDD image Pin
hoxsiew7-Aug-08 4:08
hoxsiew7-Aug-08 4:08 
GeneralRe: HDD image Pin
nutkase7-Aug-08 21:48
nutkase7-Aug-08 21:48 
Questionabout .net exe files Pin
zon_cpp6-Aug-08 18:48
zon_cpp6-Aug-08 18:48 
AnswerRe: about .net exe files Pin
Stephen Hewitt6-Aug-08 20:04
Stephen Hewitt6-Aug-08 20:04 
GeneralRe: about .net exe files Pin
zon_cpp9-Aug-08 22:50
zon_cpp9-Aug-08 22:50 
QuestionHow proxy binds to original coclass object? Pin
George_George6-Aug-08 18:47
George_George6-Aug-08 18:47 
AnswerRe: How proxy binds to original coclass object? Pin
Stephen Hewitt6-Aug-08 19:46
Stephen Hewitt6-Aug-08 19:46 
GeneralRe: How proxy binds to original coclass object? Pin
George_George6-Aug-08 19:55
George_George6-Aug-08 19:55 
GeneralRe: How proxy binds to original coclass object? Pin
Stephen Hewitt6-Aug-08 20:02
Stephen Hewitt6-Aug-08 20:02 
GeneralRe: How proxy binds to original coclass object? Pin
George_George6-Aug-08 20:12
George_George6-Aug-08 20:12 
GeneralRe: How proxy binds to original coclass object? Pin
Stephen Hewitt6-Aug-08 20:16
Stephen Hewitt6-Aug-08 20:16 
GeneralRe: How proxy binds to original coclass object? Pin
George_George6-Aug-08 20:23
George_George6-Aug-08 20:23 
GeneralRe: How proxy binds to original coclass object? Pin
Stephen Hewitt6-Aug-08 20:28
Stephen Hewitt6-Aug-08 20:28 
GeneralRe: How proxy binds to original coclass object? Pin
George_George6-Aug-08 20:47
George_George6-Aug-08 20:47 
GeneralRe: How proxy binds to original coclass object? Pin
Stephen Hewitt6-Aug-08 20:53
Stephen Hewitt6-Aug-08 20:53 

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.