Can LiveCode Do This for Mobile Devices...?

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
Gage
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 224
Joined: Tue Mar 26, 2013 8:59 pm

Can LiveCode Do This for Mobile Devices...?

Post by Gage » Sat Oct 10, 2015 12:48 pm

Hello!

I just have a question about whether the following would be possible in LiveCode. I might want to create an app that, while it's open, can detect an incoming text message or phone call to the mobile device. Upon identifying that the identity of the caller/texter is among a pre-defined list of numbers, a pre-written message would be automatically sent to that person in response as a text.

It's a lot like the feature in a phone's calling app that allows one to ignore a call and respond with a text, but it would obviously be a third-party app that would be running outside of the telephony and messaging services. Does LiveCode receive those phone activities in a handler that can do what I specified above? If so, what calls handle them?

Thanks in advance!

Phil E.

CoreySchroeder
Posts: 26
Joined: Mon Sep 14, 2015 4:31 am

Re: Can LiveCode Do This for Mobile Devices...?

Post by CoreySchroeder » Sat Oct 10, 2015 8:41 pm

I'm dabbling a bit with mobile development, so I'll pitch in a small piece to this puzzle for you.

There is a built-in function that will allow you to send a predefined message to a specific number.
Check out the dictionary for more information.

Code: Select all


//   Format - mobileComposeTextMessage  "phone number", "predefined text"

mobileComposeTextMessage  "555 555 5555",  "Hi there, this is a predefined message that is being messaged to you"

I haven't played around with this, but I'm sure there would be a way to set various numbers or various messages by using variables - I could be wrong...

Code: Select all


// Something like this -

put "555 555 5555" into varNumber
put "Hello!" into varMessage

mobileComposeTextMessage varNumber, varMessage

I'm not sure, however if you can intercept an incoming text or call, save that phone number to a variable, then test that phone number against your predefined list of contacts.

You may want to post this thread in the "Application Specific" section of the forums - under the appropriate device you plan to develop this app for - you'll likely get far more relevant answers.

Good Luck!

Gage
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 224
Joined: Tue Mar 26, 2013 8:59 pm

Re: Can LiveCode Do This for Mobile Devices...?

Post by Gage » Sat Oct 10, 2015 11:56 pm

Corey,

That is a great suggestion for that part of my question, thank you!! :D

As for your advice about trying the forum... good suggestion, I'll follow it. Thanks for taking the time to respond!

All the best,
Phil E.

Post Reply