Triggers: Difference between revisions

31 bytes removed ,  7 October 2016
m
no edit summary
mNo edit summary
mNo edit summary
Line 445: Line 445:


<source lang="javascript">
<source lang="javascript">
msg = "Dear, " + entry().field("ContactName") +
msg = "Dear, " +
     "\n" + entry().field("Notes")                 // Form the message from ContactName & Notes
    entry().field("ContactName") +
i = intent("android.intent.action.SENDTO")       // Create intent object to open the app for sending
     "\n" + entry().field("Notes")         // Form the message from ContactName & Notes
i.data("smsto:"+entry().field("Phone"))           // Provide the phone number in format smsto:number
i = intent("android.intent.action.SENDTO") // Create intent object to open the app for sending
i.extra("sms_body" , msg)                         // Insert the text of the message to sms_body
i.data("smsto:"+entry().field("Phone"))   // Provide the phone number in format smsto:number
i.send()                                         // Send the message
i.extra("sms_body" , msg)                 // Insert the text of the message to sms_body
i.send()                                   // Send the message
</source>
</source>