I am using telephony: 0.2.0, flutter version: 3.3.8
I am trying to listen to message received, it works when the messages is sent by the service providers, but it doenst work when the sms is sent from another mobiles.
is anyone else experiencing this problem? is there a solution
I am using telephony: 0.2.0, flutter version: 3.3.8
I am trying to listen to message received, it works when the messages is sent by the service providers, but it doenst work when the sms is sent from another mobiles.
is anyone else experiencing this problem? is there a solution
I have also added to android manifest files.
` onBackgroundMessage(SmsMessage message) { debugPrint("onBackgroundMessage called"); mainController.newSMSReceived(message); }
@override void initState() { super.initState(); listenToNewSms(); }
listenToNewSms() async { final bool? result = await telephony.requestPhoneAndSmsPermissions;
}
onMessage(message) async { mainController.newSMSReceived(message); } `