Lui*_*bós 2 ios-bluetooth ios9
我需要打开蓝牙设置菜单IOS9.0.下一步打开设置菜单OK!,
UIApplication.sharedApplication().openURL(NSURL(string: UIApplicationOpenSettingsURLString)!)
Run Code Online (Sandbox Code Playgroud)
但是我需要打开蓝牙设置菜单
UIApplication.sharedApplication().openURL(NSURL(string: "prefs:root=General&path=Bluetooth")!)
Run Code Online (Sandbox Code Playgroud)
这是行不通的
有人可以帮帮我吗?
路易斯实际上找到了答案,但我最初读过它,因为我没有看到答案.
答: 转到您的XCode项目,在URL Scheme中的Info - > URL Types部分 - >"prefs"下
在IOS9中: let url = NSURL(string: "prefs:root=Bluetooth")!
iOS8上: let url = NSURL(string: "prefs:root=General&path=Bluetooth")!
| 归档时间: |
|
| 查看次数: |
1478 次 |
| 最近记录: |