iOS5的SDK现在可以直接打开setting页面了,以往的SDK则不可以,当时我还花了大量时间去实现,结果不了了之。
![](http://www.cocoachina.com/cms/uploads/allimg/111108/3292_111108164602_1.jpg)
- [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=LOCATION_SERVICES"]];
- [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=TWITTER"]];
如果想打开蓝牙的设置:
- [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=General&path=Bluetooth"]];
当然你还可以打开应用的设置:
- [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Apps&path=Your+App+Display+Name"]];