Android跳转WIFI界面的四种方式
第一种
Intent intent = new Intent(); intent.setAction("android.net.wifi.PICK_WIFI_NETWORK"); startActivity(intent);
第二种
startActivity(new Intent(android.provider.Settings.ACTION_WIFI_SETTINGS));
第三种
Intent i = new Intent(); if(android.os.Build.VERSION.SDK_INT >= 11){ //Honeycomb i.setClassName("com.android.settings", "com.android.settings.Settings$WifiSettingsActivity"); }else{ //other versions i.setClassName("com.android.settings" , "com.android.settings.wifi.WifiSettings"); } startActivity(i);
第四种
Intent wifiSettingsIntent = new Intent("android.settings.WIFI_SETTINGS"); startActivity(wifiSettingsIntent);