Instantly share code, notes, and snippets.

Embed
What would you like to do?
BroadcastReceiver to list WiFi networks on the SSaurel's Blog
BroadcastReceiver wifiReceiver = new BroadcastReceiver() {
@Override
public void onReceive(Context context, Intent intent) {
results = wifiManager.getScanResults();
unregisterReceiver(this);
for (ScanResult scanResult : results) {
arrayList.add(scanResult.SSID + " - " + scanResult.capabilities);
adapter.notifyDataSetChanged();
}
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment