Hi all,
i want to cancel outgoing calls. In this case I am checking the state of a RLine in a CActive. If needed I get a RMobileCall object from the Line to become access to the call. The usage of hangup(void) should cancel the call. I tried this in the EStatusDialling state and hangup didn't have an effect:
The outgoing call was generated regular above the phone and not by my application. So I thought that I can't cancel dialling because I am not the owner of the call.Code:... switch (iCallStatus) { ... case RCall::EStatusDialling: { RLine::TLineInfo lineInfo; iLine.GetInfo(lineInfo); if (iCall.OpenExistingCall(iLine, lineInfo.iNameOfLastCallAdded) == KErrNone) { iCall.HangUp(); iCall.Close(); CEikonEnv::Static()->AlertWin(_L("(dialling) hang up!")); } } break; ... } ...
BUT:
If I use he same piece of code in the EStatusConnecting state, the hangup works fine:
So I think the ownership is not the problem. Unfortunately EStatusConnecting isn't acceptable to cancel the outgoing call, because the target phone rings.Code:... switch (iCallStatus) { ... case RCall::EStatusConnecting: { RLine::TLineInfo lineInfo; iLine.GetInfo(lineInfo); if (iCall.OpenExistingCall(iLine, lineInfo.iNameOfLastCallAdded) == KErrNone) { iCall.HangUp(); iCall.Close(); CEikonEnv::Static()->AlertWin(_L("(connecting) hang up!")); } } break; ... } ...
My question:
Exists a way to cancel a call while the dialling process?
(I tried iCall.DialCancel() and iCall.Close(), too. But these functions have other jobs.) Addionally I tried to get the ownership of the call with iCall.AcquireOwnership(acquireState), but it fails.
I hope that somebody can help me...
Thank you & Cheers



