Hi all,
I have a socket receive function and I want to set a custom time out value of 1000 MicroSeconds. (i.e. if a socket is not recieved within 1000 Microseconds it should go to RunL() ).
How can this be done ?
Regards,
Primal
Hi all,
I have a socket receive function and I want to set a custom time out value of 1000 MicroSeconds. (i.e. if a socket is not recieved within 1000 Microseconds it should go to RunL() ).
How can this be done ?
Regards,
Primal
You have to implement a separate active object for that (containing the timer). There you can Cancel the first one (pass a reference to it), and so on. Of course the Cancel should be mutual - basically CSocketBlabla::RunL should start with iTimerActive->Cancel(), and CTimerActive::RunL should start with iSocketBlabla->Cancel().
Hi,
I tried the followign way having socket send is written in a one class and the timer is in another class.
But when the timer expires (after 300000 micro seconds), the whole program get closed. What could be the reason ?Code:socketCls->send(); TTimeIntervalMicroSeconds32 aDelay = 30000; iTimer.After( iStatus, aDelay ); if (socketCls->iStatus.Int() == 0) { //socketCls->Cancel(); TBuf<128> content; //content.Copy(_L("Patner is missing")); content.Num(socketCls->iStatus.Int()); CEikonEnv::InfoWinL(_L(" -- // -- value is "),content); }
Regards,
Primal
Your application panics so all you have to do is retrieve the panic reason and code and then identify and fix the problem.
-- Lucian