Rar*_*can 4 location windows-phone-8
我想检查位置服务是否已打开或关闭,因此我可以通知用户他需要打开它以便在地图上查看他的位置.还想检查飞行模式是否打开/关闭以及是否打开/关闭WiFi.有什么建议?
and*_*ubi 19
位置:
Geolocator locator = new Geolocator();
if (locator.LocationStatus == PositionStatus.Disabled)
{
// Location is turned off
}
Run Code Online (Sandbox Code Playgroud)
对于网络资料,请参阅DeviceNetworkInformation
课程.例如
bool isWifiOn = DeviceNetworkInformation.IsWiFiEnabled;
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
2292 次 |
最近记录: |