Grokking Android

Getting Down to the Nitty Gritty of Android Development

Posts tagged “BroadcastReceiver”:

Android Quick Tip: Enabling and Disabling BroadcastReceivers at Runtime


BroadcastReceivers are good when you want to be notified about system events. But sometimes you do need to know about an event only once or for a short period of time. A dynamically registered receiver doesn’t cut it because the Activity and it’s dynamically registered broadcast receiver might long be dead when the event occurs. […]  Continue Reading  “Android Quick Tip: Enabling and Disabling BroadcastReceivers at Runtime”

Android Tutorial: BroadcastReceiver


Whenever you want to know about system wide events you need to implement and register a BroadcastReceiver. From then on your receiver gets notifications whenever the system event, for which it is registered, occurs. BroadcastReceivers are one of Android’s four standard components. What are BroadcastReceivers good for? The fact that Android informs you about system […]  Continue Reading  “Android Tutorial: BroadcastReceiver”

Android: Getting Notified of Connectivity Changes


In a previous posting I have explained how you can check the device’s current connectivity status. But this is only a temporary snapshot of the status. It might change anytime – and it probably will, given the volatility of a mobile environment. Thus you want to know whenever the connectivity state changes. Thankfully Android’s ConnectivityManager […]  Continue Reading  “Android: Getting Notified of Connectivity Changes”