Click here to Skip to main content
15,902,777 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Exit the thread after specified thread Pin
CPallini9-May-08 0:11
mveCPallini9-May-08 0:11 
GeneralRe: Exit the thread after specified thread Pin
Hamid_RT9-May-08 0:23
Hamid_RT9-May-08 0:23 
GeneralRe: Exit the thread after specified thread Pin
CPallini9-May-08 0:37
mveCPallini9-May-08 0:37 
GeneralRe: Exit the thread after specified thread Pin
manju#1239-May-08 1:06
manju#1239-May-08 1:06 
GeneralRe: Exit the thread after specified thread Pin
CPallini9-May-08 1:56
mveCPallini9-May-08 1:56 
GeneralRe: Exit the thread after specified thread Pin
manju#1239-May-08 2:06
manju#1239-May-08 2:06 
GeneralRe: Exit the thread after specified thread Pin
CPallini9-May-08 2:15
mveCPallini9-May-08 2:15 
GeneralRe: Exit the thread after specified thread Pin
manju#1239-May-08 2:20
manju#1239-May-08 2:20 
here code.



////////////////////////

COleDateTime StartTime,CurrTime;
COleDateTime EndTime;
CString StTime,CurTime;

cDuration = _ttoi(linfo->sDuration);
StartTime = COleDateTime::GetCurrentTime();
CurrTime = COleDateTime::GetCurrentTime();
CurTime.Format("%02d:%02d:%02d",CurrTime.GetHour(),CurrTime.GetMinute(),CurrTime.GetSecond());
COleDateTimeSpan ts(0,0,cDuration,0);
EndTime = StartTime + ts;
StTime.Format("%02d:%02d:%02d",EndTime.GetHour(),EndTime.GetMinute(),EndTime.GetSecond());


if(linfo->bServerConnected==false)
{
if(CurTime <= StTime)
{
linfo->btimeOut = false;
}
else
linfo->btimeOut = true;


if(CurTime <= StTime)
while(linfo->btimeOut == false)
{
run the thread



if(CurTime == StTime)
{
linfo->btimeOut = true;
ExitThread(dwExitCode);
_endthread();

}
}

//////////////////////////////////////////////////////

thank you

Hi..
I am Mnaju.I have Completed my B.E Computers Science.Lokking for a job.I am interested in VC++
manju

GeneralRe: Exit the thread after specified thread Pin
CPallini9-May-08 3:19
mveCPallini9-May-08 3:19 
QuestionMic Detection Using mixer APIs Pin
pvn g8-May-08 23:14
pvn g8-May-08 23:14 
AnswerRe: Mic Detection Using mixer APIs Pin
Hamid_RT9-May-08 0:14
Hamid_RT9-May-08 0:14 
QuestionORACLE Commit problem--- Error 8197 Pin
megha_gharote8-May-08 22:58
megha_gharote8-May-08 22:58 
AnswerRe: ORACLE Commit problem--- Error 8197 Pin
toxcct8-May-08 23:15
toxcct8-May-08 23:15 
GeneralRe: ORACLE Commit problem--- Error 8197 Pin
megha_gharote8-May-08 23:19
megha_gharote8-May-08 23:19 
AnswerRe: ORACLE Commit problem--- Error 8197 Pin
Rajesh R Subramanian8-May-08 23:32
professionalRajesh R Subramanian8-May-08 23:32 
QuestionHow to invoke application/service on another computer Pin
AnhKhoi8-May-08 22:48
AnhKhoi8-May-08 22:48 
AnswerRe: How to invoke application/service on another computer Pin
toxcct8-May-08 23:18
toxcct8-May-08 23:18 
GeneralRe: How to invoke application/service on another computer Pin
AnhKhoi9-May-08 0:31
AnhKhoi9-May-08 0:31 
GeneralRe: How to invoke application/service on another computer Pin
toxcct9-May-08 1:01
toxcct9-May-08 1:01 
QuestionDialog application Pin
tom groezer8-May-08 22:28
tom groezer8-May-08 22:28 
AnswerRe: Dialog application Pin
Matthew Faithfull8-May-08 22:42
Matthew Faithfull8-May-08 22:42 
AnswerRe: Dialog application Pin
CPallini8-May-08 22:43
mveCPallini8-May-08 22:43 
AnswerRe: Dialog application Pin
toxcct8-May-08 23:13
toxcct8-May-08 23:13 
GeneralRe: Dialog application Pin
tom groezer9-May-08 2:34
tom groezer9-May-08 2:34 
GeneralRe: Dialog application Pin
toxcct9-May-08 3:03
toxcct9-May-08 3:03 

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.