Question

I don't know whether it's possible: I need to register my android app (it's a backgroundservice) to let it know, when the android system is scanning for wlan-hotspots. I don't want to do this manually in my service every 5 minutes because of battery-reasons.

Is there a way to call my service everytime the os is scanning the wlan?

Was it helpful?

Solution

you need to register broadcast receiver for that with ConnectivityManager.CONNECTIVITY_ACTION action look for this article http://www.krvarma.com/2010/08/android-network-connectivity-broadcastreceiver/

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top