-
Notifications
You must be signed in to change notification settings - Fork 119
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Listening to incoming messages #174
Comments
Yes, I am also facing this issue. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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);
}
`
The text was updated successfully, but these errors were encountered: