Android Question SMS Interceptor not capturing

Richard Phipps

Member
Licensed User
I copied some code from an old app pre-google permissions but now it no long seems to work on my new s21. I asked for permissions which were granted on first app run

On my Samsung S21 the drop down window appears giving options to reply or call or mark as read. Could this be interferring with the capture? If so is it possible to prioritize my app? Does 999 need to be bigger?

B4X:
Sub GetP

Dim rp As RuntimePermissions
    rp.CheckAndRequest(rp.PERMISSION_RECEIVE_SMS)
    wait for Activity_PermissionResult(permission As String, result As Boolean)
    If result=True Then

        Log("User Permission Granted")

       
    End If
   
    SMSIntercept.Initialize2("SI",999)
    Log("Initilize interceptor")
       
End Sub

Sub SI_MessageReceived(from As String, msg As String) As Boolean

    'This is triggered when the the messages is received!
    'Return true indicates all ok!
    Log("Message received")
    Log(msg)
    Log(from)
   
    Return True

End Sub
 

mcqueccu

Well-Known Member
Licensed User


You will have to switch to this

 
Upvote 0
Top