有些功能只能從系統設定App,那麼我們就必須知會使用者,若可以的話就導向系統設定App吧~

/**
Theme: Open Setting App
IDE: Xcode 8
Language: Objective C
Date: 105/12/28
Author: HappyMan
Blog: https://cg2010studio.wordpress.com/
*/
-(void)pushSettingAction:(id)sender
{
if (/* DISABLES CODE */ (&UIApplicationOpenSettingsURLString) != nil) {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]];
}
else {
DxLog(@"UIApplicationOpenSettingsURLString is not available in current iOS version");
}
}
這樣我就能導向原本App(以垃圾管家為例)的系統設定囉~
參考:How to open Settings programmatically like in Facebook app?。
隨意留個言吧:)~