Skip to main content

How to know if an incoming call happened?

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
3 replies [Last post]
abuhmead1987
Offline
Joined: 2010-04-21

Dear Guys,

I want to know when an incoming calls happened. I want to stop the timer while the call is active, when the call be not active i want to activating the timer.

Could I handle this in LWUIT?

Thanks a lot in advance,

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
vprise
Offline
Joined: 2003-11-07

You can't detect incoming calls. You can override the MIDlet pause method which *should* get called in such occasions after which startApp will be invoked again to resume your app.

abuhmead1987
Offline
Joined: 2010-04-21

I put Log.p("On resume called"); in onResume method and I tried to call my self,

when the dialer number appeared the app disappeared and when i accepted the call the app appeared again, I saw the log but no lines written. So, I cant handel this issue in onResume method.

Please try it, and tell me what i shall do.

Thanks a lot in advance,

Mohammad Abu Hmead

vprise
Offline
Joined: 2003-11-07

MIDlets startApp will be invoked again