标签:
#region 获得当前的网络连接状态 public static bool CheckNetwork() { bool isOnline = false; //获得当前的网络连接状态 ConnectionProfile InternetConnectionProfile = NetworkInformation.GetInternetConnectionProfile(); if (InternetConnectionProfile == null) { //断网情况下 } else { isOnline = true; } return isOnline; } #endregion
标签:
原文地址:http://www.cnblogs.com/lyl6796910/p/4672705.html