0

The Broadcast receiver to read phone State will work fine for android version < 6, but in Nouget it only work if the App is in foreground or backgroung.

If we kill the App then the the the broadcast onreceive function won't call. is there a way to start the Service in background.

  • have you tried https://stackoverflow.com/questions/45994470/android-broadcast-receiver-call-and-sms-received-not-working-in-android-nougat – Akhilesh Awasthi Jan 24 '18 at 14:08

1 Answers1

0

static broadcast is completely deprecated from Naugat onwards. so android os will not deliver intent to your receiver

AKASH WANGALWAR
  • 1,326
  • 1
  • 14
  • 21
  • So how to notify the user if a new outgoing Call or Incomming call comes ?? if static broadcast is completely deprecated from Naugat onwards So what was the other option to do the same task – Quality Singh Jan 25 '18 at 05:04
  • have you got the permission for READ_PHONE_STATE with run time permission. – AKASH WANGALWAR Jan 25 '18 at 06:14
  • yes i got the permission for READ_PHONE_STATE with run time permission ... the App is working fine if the App is in recent or in Forground...but if we clear the App from the Recent the Broadcast onrecieve function wont call if we make a cal or new incoming call is coming. – Quality Singh Jan 25 '18 at 06:51