Also, what does your app do?
Please provide a lot of details.
It's just a shared phone list. Stores name, 2 phones and email. That's it. It is designed for certain small groups to keep a phone list. You can join multiple groups but you must be "invited" to join by a member of the group. It is for a specific segment. You can't even create you own group initially. You have to send a request to me and I create the group. Currently these groups keep manual phone lists if they can get someone to do it which just seems absurd to me in this day and age so I thought I would make it easier. All I am doing, when the tap the phone # is ask: Call or Text. If they pick text it opens the default text app.
[CODE lang="b4x" title="#If B4A '8/31/21 - remmed below and removed SMS from manifest Dim CallReason As String = "In order for this program to send texts, your permission is required. The next screen will ask for that permission. If you deny permission, then this program can not start a text message for you." Dim RP As RuntimePermissions If RP.Check(RP.PERMISSION_SEND_SMS) = False Then 'if no existing phone call permission MsgboxAsync(CallReason, "Texts Permission") 'explain why this apps needs call permission Wait For MsgBox_Result (Result As Int) RP.CheckAndRequest(RP.PERMISSION_SEND_SMS) 'prompt for permission Wait For Activity_PermissionResult (Permission As String, AskResult As Boolean) If AskResult = False Then 'user did not give permission MsgboxAsync("User refused permission, cannot start texts.", "Texts Permission") Return 'abort text End If End If Dim in As Intent in.Initialize(in.ACTION_VIEW, $"sms:${Num}"$) If Msg.Length > 0 Then in.PutExtra("sms_body", Msg) StartActivity(in) #ELSE If B4i If Main.App.CanOpenUrl($"sms:"$) = False Then MP.xui.MsgboxAsync("Unable to open text app.", "Can't open sms") Else If Msg.Length > 0 Then Msg = Msg.Replace(" ", "%20") If Msg.Length > 0 Then Msg = Msg.Replace(CRLF, "%0D%0A") Num = Num.Replace(" ", "") Num = Num.Replace(CRLF, "") Main.App.OpenUrl($"sms:${Num}&body=${Msg}"$) End If #End If"] #If B4A
'8/31/21 - remmed below and removed SMS from manifest
Dim CallReason As String = "In order for this program to send texts, your permission is required. The next screen will ask for that permission. If you deny permission, then this program can not start a text message for you."
Dim RP As RuntimePermissions
If RP.Check(RP.PERMISSION_SEND_SMS) = False Then 'if no existing phone call permission
MsgboxAsync(CallReason, "Texts Permission") 'explain why this apps needs call permission
Wait For MsgBox_Result (Result As Int)
RP.CheckAndRequest(RP.PERMISSION_SEND_SMS) 'prompt for permission
Wait For Activity_PermissionResult (Permission As String, AskResult As Boolean)
If AskResult = False Then 'user did not give permission
MsgboxAsync("User refused permission, cannot start texts.", "Texts Permission")
Return 'abort text
End If
End If
Dim in As Intent
in.Initialize(in.ACTION_VIEW, $"sms:${Num}"$)
If Msg.Length > 0 Then in.PutExtra("sms_body", Msg)
StartActivity(in)
#ELSE If B4i
If Main.App.CanOpenUrl($"sms:"$) = False Then
MP.xui.MsgboxAsync("Unable to open text app.", "Can't open sms")
Else
If Msg.Length > 0 Then Msg = Msg.Replace(" ", "%20")
If Msg.Length > 0 Then Msg = Msg.Replace(CRLF, "%0D%0A")
Num = Num.Replace(" ", "")
Num = Num.Replace(CRLF, "")
Main.App.OpenUrl($"sms:${Num}&body=${Msg}"$)
End If
#End If
[/CODE]
Apple doesn't have any problem with what I am doing.