Languages

Menu
Sites
Language
How to open the SMS compose screen?

Hello,

How can I open the SMS compose screen (from the system Messaging app) from a web app? Seems that <a href="sms:number"> does not work, but <a href="mailto:something@some.com?subject=test"> works...

Thanks

Responses

6 Replies
Marco Buettner

Use launchAppControl :)

konduri sai swathi

Hi,

Try the below code :

function onsuccess() {
    	console.log("The application has launched successfully");
}
tizen.application.launch("8r4r5ddzzn.Messages", onsuccess);

 

Alexander AVSukhov

Hello,

You may use Application Control.

More information:

https://developer.tizen.org/help/index.jsp?topic=%2Forg.tizen.native.appprogramming%2Fhtml%2Fguide%2Fapp%2Fappcontrol_message.htm

Although they are documents for native APIs, but the mechanism is same.

Cristian Loloiu

Getting ":launch appControl failed. Reason: NotFoundError" when trying to launch http://tizen.org/appcontrol/operation/compose Application Control.

Alexander AVSukhov

Hello,

Try to use:

var appControl = new tizen.ApplicationControl("http://tizen.org/appcontrol/operation/compose", null, null, null,
            [new tizen.ApplicationControlData("http://tizen.org/appcontrol/data/to", ["+7894"])]);

    tizen.application.launchAppControl(
             appControl,
             "tizen.smsmessages",
             function() {console.log("launch application control succeed"); },
             function(e) {console.log("launch application control failed. reason: " + e.message); },
             null );

Cristian Loloiu

This works, thank you!

You saved me from a few hours of researching/coding :)