Create new sms message with text

walterfn2

Member
Licensed User
Longtime User
I want to add function to my app, when user clicks button, phone opens "New sms message" already with some text.
Is it possible to create new sms message already with some text using intent?

Thank you
 

davidmd

Member
Licensed User
Longtime User
Requires a reference to the Phone library

SMS
Code:
Dim i As Intent
i.Initialize(i.ACTION_VIEW, "sms:0123456789")
i.PutExtra("sms_body", "write text here")
StartActivity(i)


Requires a reference to the Phone library
 
Upvote 0

BarrySumpter

Active Member
Licensed User
Longtime User
Works! And follow up question.

WOW!:sign0098:
Just what I was looking for my first app.

I thought I might see how quickly I can develop a B4A QuickCalls app.

My daughter Tatiana needs a lot of chauffeuring to and from gatherings.
Dropping off is easy.

But pickups are a bit volitile.

I don't go into the gatherings so as not to embarrass her or put pressure on her to leave.
Nor scare the other kids who want to relax and have fun.

When I get into the car I'll SMS her that I am on my way so she can start her good-byes.
When I'm a block or two away I'll SMS her that I'm here so she will come out straight away.

I'm hoping my QuickCalls app will help with these repetative, mundane, and distracting tasks.

After setup etc and using this script, perhaps 8 minutes later
Its all happening!

Very frekin' cool!


Is there a way I can send a command to the sms client to go ahead and send the message without pausing for me to press the send button?
 

Attachments

  • QuickCalls.jpg
    QuickCalls.jpg
    14.5 KB · Views: 268
Last edited:
Upvote 0

BarrySumpter

Active Member
Licensed User
Longtime User
Hi Brad,
Thanks for the reply.
The s.send command fires my sms client with the appropriate fields filled in.
But just sits there.

Is there any way to programatically go ahead and send the message without pausing?
 
Upvote 0
Top