SMS message

Mark Smith mark at maseurope.net
Tue Apr 17 18:29:21 EDT 2007


You could also use placeholders with the replace command.


So store this in a field or a custom prop.
  tell application "SMS Mac Scripting"
                            set account to "!ACCOUNT!"
                            set pin to "!PIN!"
                            set m to make new outgoing sms with  
properties {flash:false}
                            tell m
                                  set message to "!MESSAGE!"
                                  set recipients to {!RECIPIENTS!}
                                  set sender to "!SENDER!"
                                  set delivery report to true
                                  try
                                        send
                                  on error errMsg number errNum
                                        display dialog "Error: " &  
errNum & ". " & errMsg
                                  end try
                            end tell
                      end tell
Liam Lambert

then,

on sendAMessage pAccount, pPin, pMessage, pRecipients, pSender
   put fld "message" into tScript
   replace "!ACCOUNT!" with pAccount in tScript
   replace "!PIN!" with pPin in tScript
  etc. etc


then
do tScript as applescript.


Also, check out http://www.sms2email.com/index.php, a bit cheaper, I  
think, and you can use POST,GET, and email to send...

Best,

Mark



More information about the use-livecode mailing list