When to unregister BroadcastReceiver? In onPause(), onDestroy(), or onStop()?

it depends on where you have register the receiver. The complementary method pairs are

onCreate - onDestroy
onResume - onPause
onStart  - onStop

if you register the receiver in the first one then unregister it in it’s ending method.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)