I am working on Symbian S60 2nd Edition SDK for C++ (Symbian 7.0s) and Codewarrior IDE.
I am facing some issues while trying to use two asynchronous requests in an application.
I had an AppUI class which contains handles (pointers) to two engines:
1. Call Watch Engine: Which Monitor the phone line and disconnect if there is any call.
2. SMS Engine: Used to send SMS.
Both call-watch and SMS class make use of active objects.
The APPUI calls Start() function of CCallWatchEngineclass:
and I am handling the line status in the RunL() Method of the CallWatchEngine class:
//disconnect the call if it is dialing or ringing state
Now, once I disconnect the call, I try to send a SMS but calling SendSMSL() function of APPUI which intern calls SaveAndSendSMSL() of CMtmEngineClass.
//Prepare the SMS
//Call Asynchronous function to send the SMS
Now everything works fine for the first time.
I dial a call, it is disconnected and SMS is sent. But while trying second time, nothing happens. That means the CCallWatchEngine is not able to get the Line notification. However, if I restart the application, it works again only for the first time.
I also tried to call Start() function of CCallWatchEngine after the SMS is sent (i.e. from RunL() of CMtmEngine).
Please let me know if I am doing something wrong. If yes, what will be the best way to do this.
Thanks & Br,