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: 7
Registered: ‎02-09-2013
My Device: BlackBerry Z10
My Carrier: VivaCell

How to invoke "Text Messages" app to compose sms ?

Hello,

 

I'm trying to invoke the native app for sending sms, but can't figure out the invocation parameters.

The sample app "invoke client" and

https://developer.blackberry.com/cascades/documentation/device_platform/invocation/email.html

 

 documentation allow me to invoke composer for email, but not for text messages.

 

Any suggestion is highly appreciated.

 

 Thanks,
    Narek

Developer
Posts: 671
Registered: ‎03-21-2012
My Device: BlackBerry PlayBook 16GB
My Carrier: Vip

Re: How to invoke "Text Messages" app to compose sms ?

As far as I know, it's not documented yet. But it's available.

 

<invoke-target id="sys.pim.text_messaging.uib.view">
        <type>card.previewer</type>
        <filter>
            <action>bb.action.REPLY</action>
            <mime-type>application/vnd.blackberry.sms</mime-type>
            <mime-type>application/vnd.blackberry.mms</mime-type>
            <property var="uris" value="pim:"/>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging.uib.compose">
        <type>card.previewer</type>
        <filter>
            <action>bb.action.FORWARD</action>
            <mime-type>application/vnd.blackberry.sms</mime-type>
            <mime-type>application/vnd.blackberry.mms</mime-type>
            <property var="uris" value="pim:"/>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging.composer">
        <type>card.previewer</type>
        <filter>
            <action>bb.action.COMPOSE</action>
            <mime-type>application/text_messaging</mime-type>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging.previewer">
        <type>card.previewer</type>
        <filter>
            <action>bb.action.VIEW</action>
            <mime-type>application/text_messaging</mime-type>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging.sharemedia">
        <invoke-target-type>card.previewer</invoke-target-type>
        <type>card.previewer</type>
        <icon><image>share_icon.png</image></icon>
        <filter>
            <!-- Single File share -->
            <action>bb.action.SHARE</action>
            <mime-type>*</mime-type>
            <property var="uris" value="file://"/>
        </filter>
        <filter>
            <!-- Multi-File share -->
            <action>bb.action.SHARE</action>
            <mime-type>filelist/*</mime-type>
            <property var="uris" value="list://"/>
        </filter>
        <filter>
            <!-- Contact card sharing -->
            <action>bb.action.SHARE</action>
            <mime-type>*</mime-type>
            <property var="uris" value="file://"/>
            <property var="exts" value="vcf"/>
        </filter>
        <filter>
          <action>bb.action.SHARE</action>
          <mime-type>text/plain</mime-type>
          <mime-type>application/vnd.blackberry.string.address</mime-type>
       </filter>
        <filter>
            <!-- Browser share link -->
            <action>bb.action.SHARE</action>
            <mime-type>*</mime-type>
            <property var="uris" value="http://,https://"/>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging">
        <type>card.previewer</type>
        <icon><image>share_icon.png</image></icon>
        <filter>
            <action>bb.action.SENDTEXT</action>
            <mime-type>application/vnd.blackberry.string.phone</mime-type>
        </filter>
        <filter>
            <action>bb.action.SENDTEXT</action>
            <mime-type>application/vnd.blackberry.string.contact</mime-type>
        </filter>
        <filter>
            <action>bb.action.SENDTEXT</action>
            <mime-type>*</mime-type>
            <property var="uris" value="tel:"/>
        </filter>
    </invoke-target>
    <invoke-target id="sys.pim.text_messaging.smsuri">
        <type>card.previewer</type>
        <icon><image>share_icon.png</image></icon>
        <filter>
            <action>bb.action.OPEN</action>
            <mime-type>*</mime-type>
            <property var="uris" value="sms:,smsto:"/>
        </filter>
    </invoke-target>
    
    <!-- CROSS-PERIMETER -->
    <invoke-target id="sys.pim.text_messaging.smsuri.entr">
        <type>card.composer</type>
        <icon><image>share_icon.png</image></icon>
        <filter>
            <action>bb.action.OPEN</action>
            <mime-type>*</mime-type>
            <property var="perimeter" value="enterprise"/>
            <property var="uris" value="sms:,smsto:"/>
        </filter>
        <filter>
            <action>bb.action.SENDTEXT</action>
            <mime-type>*</mime-type>
            <property var="perimeter" value="enterprise"/>
            <property var="uris" value="sms:,smsto:,tel:"/>
        </filter>
    </invoke-target>

 

New Developer
Posts: 7
Registered: ‎02-09-2013
My Device: BlackBerry Z10
My Carrier: VivaCell

Re: How to invoke "Text Messages" app to compose sms ?

Thank you very much. It works - now I'm able to invoke the sms composer,

just still can't figure out how to populate 'number', and 'body' fields together.
I suppose it should be achieved by sms:, and smsto: parameters in uris, but wasn't able to make it work. Only number field is being initialized.

 

If you have done such thing and can suggest more, that will be great.

 

 Thanks a lot.

 

Retired
Posts: 249
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to invoke "Text Messages" app to compose sms ?

Hi,
Apologies for the delay. Our docs team is currently preparing the docs for sms/mms invocation. They should be online in a week or so.

Shadid
Highlighted
New Developer
Posts: 7
Registered: ‎02-09-2013
My Device: BlackBerry Z10
My Carrier: VivaCell

Re: How to invoke "Text Messages" app to compose sms ?

Ok. Thank you very much!
Looking forward to it.

Narek
Trusted Contributor
Posts: 207
Registered: ‎05-02-2010
My Device: various
My Carrier: AT&T

Re: How to invoke "Text Messages" app to compose sms ?

borceg,
do you know how to set the recipient for sms? I want people to type whatever message they want, but have it sent to a specific number (set by variable)
If you are the original poster (OP) and your issue is solved, please remember to click the "Accept as Solution" button so that others can more easily find it. If anyone has been helpful to you, please show your appreciation by clicking the Star on the left of their post.
Developer
Posts: 671
Registered: ‎03-21-2012
My Device: BlackBerry PlayBook 16GB
My Carrier: Vip

Re: How to invoke "Text Messages" app to compose sms ?

Nope, sorry.
Developer
Posts: 100
Registered: ‎10-01-2012
My Device: BB10 Dev Alpha
My Carrier: Roger

Re: How to invoke "Text Messages" app to compose sms ?

Could your team also have a example on it? Thank you.