I have a question for Telephony plugin,
I am developing a sms app with Flutter framework, and the developing sms app must have a function that can let my flutter sms app set as default sms app,In order to complete this,I invoked a method channel from Android native layer and worked normally,
It included several relative configure options in “AndroidManifest.xml”,the four configurations are all required,otherwise couldn’t work, according to the link https://stackoverflow.com/questions/30127564/how-do-i-set-my-app-as-the-default-sms-app to finish it, the above steps are correct, then followed Telephone plugin’s instructions to receive incoming sms message, once I sent any test sms message, would appear an error message that showed as below:
"java.lang.RuntimeException: Unable to instantiate receiver com.example.fluttertest7.SmsReceiver: java.lang.ClassNotFoundException: Didn't find class "com.example.fluttertest7.SmsReceiver" on path....."
According to Telephony's manual, the mapped configuration of “AndroidManifest.xml” is
<receiver android:name="com.shounakmulay.telephony.sms.IncomingSmsReceiver" android:permission="android.permission.BROADCAST_SMS" android:exported="true"> <intent-filter> <action android:name="android.provider.Telephony.SMS_RECEIVED"/> </intent-filter> </receiver>
It looks like a conflict problem?They can not exist together?Once I removed the four configuration of “default sms app”,will receive incoming message,I am pretty confused for that, please help! Thanks a lot.