This may be a silly question, is it possible to amend this part of the code to run in a Service? If not, how can you get the default package?
Thanks!
Thanks!
B4X:
Dim context As JavaObject = Activity
context = context.RunMethod("getContext", Null)
Dim so As JavaObject
Dim package As String = so.InitializeStatic("android.provider.Telephony.Sms").RunMethod( _
"getDefaultSmsPackage", Array As Object(context))