Android App Development
Saturday, 6 April 2013
Android Wifi How to enable and disable Wifi?
The WifiManager can be used to enable and disable wifi. Where 'enabled' is a boolean.
WifiManager
wifi
=
(
WifiManager
)
getSystemService
(
Context
.
WIFI_SERVICE
);
wifi
.
setWifiEnabled
(
enabled
);
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
Disqus for Android
No comments:
Post a Comment