Click here to Skip to main content
15,908,264 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Text Boxes in C++ Pin
Eytukan16-Jan-06 2:32
Eytukan16-Jan-06 2:32 
AnswerRe: Text Boxes in C++ Pin
Gktony16-Jan-06 3:13
Gktony16-Jan-06 3:13 
GeneralRe: Text Boxes in C++ Pin
toxcct16-Jan-06 3:24
toxcct16-Jan-06 3:24 
QuestionAccessing Namespace in other class Pin
romuzu16-Jan-06 0:42
romuzu16-Jan-06 0:42 
AnswerRe: Accessing Namespace in other class Pin
Owner drawn16-Jan-06 1:11
Owner drawn16-Jan-06 1:11 
Questionhow to use thread Pin
cancerion16-Jan-06 0:31
cancerion16-Jan-06 0:31 
AnswerRe: how to use thread Pin
Owner drawn16-Jan-06 1:18
Owner drawn16-Jan-06 1:18 
AnswerRe: how to use thread Pin
Eytukan16-Jan-06 3:07
Eytukan16-Jan-06 3:07 
Its simple as that.. (this is a worker for you!)
in the header, declare as
UINT Threader(LPVOID p);
void realThread();


in the implementation,
UINT YourDialog::Threader(LPVOID p)
{
     YourDialog* me = (YourDialog*)p;
	 me->realThread();
	 return 0;
	 
}

void realThread()
{
do
{
//blabla,..
}while(1);

}


then as said by drawn, you can use AfxBeginThread to start the thread
ie,
CWinThread *cwt=AfxBeginThread(realThread,this);
cwt->suspend();,cwt->resume();
..ect then the thread is under your control Smile | :)






0x0400:
"But your mind is very complex, very tricky. It makes simple things complicated. -- that's its work. And for centuries it has been trained for only one thing: to make things so complicated that your life becomes impossible."- Osho

<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--


AnswerRe: how to use thread Pin
ThatsAlok16-Jan-06 17:24
ThatsAlok16-Jan-06 17:24 
QuestionRescale video data Pin
dennis2416-Jan-06 0:12
dennis2416-Jan-06 0:12 
QuestionMS DataGrid Change Caption of Column Headers Pin
sdancer7515-Jan-06 22:44
sdancer7515-Jan-06 22:44 
QuestionADO 'Background Fetch Size' Pin
tuxyboy15-Jan-06 22:41
tuxyboy15-Jan-06 22:41 
QuestionLink error Pin
Russell'15-Jan-06 22:39
Russell'15-Jan-06 22:39 
AnswerRe: Link error Pin
tuxyboy15-Jan-06 22:46
tuxyboy15-Jan-06 22:46 
GeneralRe: Link error Pin
Prakash Nadar15-Jan-06 22:46
Prakash Nadar15-Jan-06 22:46 
AnswerRe: Link error Pin
Prakash Nadar15-Jan-06 22:46
Prakash Nadar15-Jan-06 22:46 
AnswerRe: Link error Pin
vallikumar16-Jan-06 17:35
vallikumar16-Jan-06 17:35 
GeneralRe: Link error Pin
Russell'15-Jan-06 23:44
Russell'15-Jan-06 23:44 
GeneralRe: Link error Pin
Prakash Nadar15-Jan-06 23:50
Prakash Nadar15-Jan-06 23:50 
GeneralRe: Link error Pin
Prakash Nadar15-Jan-06 23:52
Prakash Nadar15-Jan-06 23:52 
GeneralRe: Link error Pin
Russell'16-Jan-06 0:01
Russell'16-Jan-06 0:01 
GeneralRe: Link error Pin
Prakash Nadar16-Jan-06 0:16
Prakash Nadar16-Jan-06 0:16 
Questionunit test case Pin
bigbluff15-Jan-06 20:48
bigbluff15-Jan-06 20:48 
AnswerRe: unit test case Pin
toxcct15-Jan-06 21:40
toxcct15-Jan-06 21:40 
AnswerRe: unit test case Pin
vallikumar16-Jan-06 17:49
vallikumar16-Jan-06 17:49 

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.