Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
New Developer
Posts: 12
Registered: ‎11-18-2010
My Device: Not Specified

Monitor Voice Calls and SMS

Hi,

 

Is it possible to monitor voice calls on BB 10 by listening to incoming/outgoing call events?

If not, is there a way to access Call History files from the System? (http://developer.blackberry.com/native/beta/documentation/com.qnx.doc.native_sdk.devguide/com.qnx.do...

 

As for SMS, there seems to be an access_sms_mms permission (http://developer.blackberry.com/native/beta/documentation/com.qnx.doc.native_sdk.devguide/com.qnx.do...

Is this done by accessing System files as well?

 

Thank you.

 

BlackBerry Development Advisor
Posts: 57
Registered: ‎10-04-2012
My Device: developer
My Carrier: none

Re: Monitor Voice Calls and SMS

It is possible to monitor phone events. There is a permission access_phone which you will need to set in your bar-descriptor.xml. You will have to edit the source manually because this permission is not listed in the Application in the Momentics IDE.

 

To listen to events you can use the Phone class and connect to callUpdated signal.

Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Monitor Voice Calls and SMS

How do you make a call from an app, regardless of its development environment? How do you invoke the phone app (if there is one)?
BlackBerry Development Advisor
Posts: 57
Registered: ‎10-04-2012
My Device: developer
My Carrier: none

Re: Monitor Voice Calls and SMS

You can use the invocation framework to invoke the phone app, to dial a number. You can read about the invocation framework here and how to send invocations here.

 

To make a call, set the action to "bb.action.DIAL" and the MIME type to "application/vnd.blackberry.phone.startcall". (see InvokeRequest). The following snippet shows how to set the data for the call, note the data must be PPS encoded:

QVariantMap map;
map.insert(“number”, “15198887465”);         // required
map.insert(“line_id”, “cellular”);           // optional
map.insert(“apply_smart_dialing”, false);    // optional
QByteArray requestData = PpsObject::encode(map, NULL);

 

Highlighted
Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Monitor Voice Calls and SMS

Thanks.

How is the data mapped for other bindings like AIR?
Developer
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Monitor Voice Calls and SMS

Also, is there a source for other "standard" schemas? Like contacts, SMS, maps, etc?