public static bool IsWifiConnected()
{
bool isWifiConnected = false;
ConnectionProfile currentConnectionForInternet = NetworkInformation.GetInternetConnectionProfile();
if(currentConnectionForInternet == null)
{
return false;
}
if(currentConnectionForInternet.IsWlanConnectionProfile)
{
if(currentConnectionForInternet.GetNetworkConnectivityLevel() == NetworkConnectivityLevel.InternetAccess)
{
return true;
}
}
return false;
}

Windows 8.1 和 Windows Phone 8.1 Runtime 检测 WiFi 是否可用使用以上方法。(感觉比WP8 silverlight 麻烦-_-)

05-26 12:13