跳轉(zhuǎn)到系統(tǒng)設(shè)置的其他界面
一. 先在跳轉(zhuǎn)按鈕的點(diǎn)擊事件方法中添加如下代碼:
NSURL*url = [NSURL URLWithString:@"prefs:root=WIFI"];
if ([[UIApplication sharedApplication] canOpenURL:url])
{
[[UIApplication sharedApplication] openURL:url];
}
二. 在項(xiàng)目中的 info 中添加 URL Types
三. 添加 URL Schemes 為 prefs 的 url
四. 現(xiàn)在你的app就可以跳轉(zhuǎn)到系統(tǒng)設(shè)置的 WIFI 中去了
五. 跳轉(zhuǎn)到其他的界面的字段, 只要更換參數(shù)就可以了
NSURL*url = [NSURL URLWithString:@"prefs:root=參數(shù)"];
if ([[UIApplication sharedApplication] canOpenURL:url])
{
[[UIApplication sharedApplication] openURL:url];
}
<p>
About — prefs:root=General&path=About
Accessibility — prefs:root=General&path=ACCESSIBILITY
AirplaneModeOn— prefs:root=AIRPLANE_MODE
Auto-Lock — prefs:root=General&path=AUTOLOCK
Brightness — prefs:root=Brightness
Bluetooth — prefs:root=General&path=Bluetooth
Date& Time — prefs:root=General&path=DATE_AND_TIME
FaceTime — prefs:root=FACETIME
General— prefs:root=General
Keyboard — prefs:root=General&path=Keyboard
iCloud — prefs:root=CASTLE iCloud
Storage & Backup — prefs:root=CASTLE&path=STORAGE_AND_BACKUP
International — prefs:root=General&path=INTERNATIONAL
Location Services — prefs:root=LOCATION_SERVICES
Music — prefs:root=MUSIC
Music Equalizer — prefs:root=MUSIC&path=EQ
Music VolumeLimit— prefs:root=MUSIC&path=VolumeLimit
Network — prefs:root=General&path=Network
Nike + iPod — prefs:root=NIKE_PLUS_IPOD
Notes — prefs:root=NOTES
Notification — prefs:root=NOTIFICATIONS_ID
Phone — prefs:root=Phone
Photos — prefs:root=Photos
Profile — prefs:root=General&path=ManagedConfigurationList
Reset — prefs:root=General&path=Reset
Safari — prefs:root=Safari Siri — prefs:root=General&path=Assistant
Sounds — prefs:root=Sounds
SoftwareUpdate— prefs:root=General&path=SOFTWARE_UPDATE_LINK
Store — prefs:root=STORE
Twitter — prefs:root=TWITTER
Usage — prefs:root=General&path=USAGE
VPN — prefs:root=General&path=Network/VPN
Wallpaper — prefs:root=Wallpaper
Wi-Fi — prefs:root=WIFI
Setting—prefs:root=INTERNET_TETHERING
<p>
常用參數(shù)
英文 參數(shù) 中文
About prefs : root=General&path=About
Accessibility prefs:root=General&path=ACCESSIBILITY
Airplane Mode On prefs:root=AIRPLANE_MODE 飛行模式
Auto-Lock prefs:root=General&path=AUTOLOCK
Brightness prefs:root=Brightness
Bluetooth prefs:root=General&path=Bluetooth 藍(lán)牙
Date & Time prefs:root=General&path=DATE_AND_TIME 日期
FaceTime prefs:root=FACETIME 視頻
General prefs:root=General
Keyboard prefs:root=General&path=Keyboard 鍵盤
iCloud prefs:root=CASTLE 云
iCloud Storage & Backup prefs:root=CASTLE&path=STORAGE_AND_BACKUP 云存儲(chǔ)與備份
International prefs:root=General&path=INTERNATIONAL
Location Services prefs:root=LOCATION_SERVICES 位置服務(wù)
Music prefs:root=MUSIC 音樂(lè)
Music Equalizer prefs:root=MUSIC&path=EQ 音樂(lè)均衡器
Music Volume Limit prefs:root=MUSIC&path=VolumeLimit 音樂(lè)音量限制
Network prefs:root=General&path=Network 網(wǎng)絡(luò)
Nike + iPod prefs:root=NIKE_PLUS_IPOD
Notes prefs:root=NOTES
Notification prefs:root=NOTIFICATIONS_ID 通知
Phone prefs:root=Phone 電話
Photos prefs:root=Photos 照片
Profile prefs:root=General&path=ManagedConfigurationList
Reset prefs:root=General&path=Reset 重啟
Safari prefs:root=Safari 瀏覽器
Siri prefs:root=General&path=Assistant 語(yǔ)音控制
Sounds prefs:root=Sounds 音效
Software Update prefs:root=General&path=SOFTWARE_UPDATE_LINK 軟件更新
Store prefs:root=STORE
Twitter prefs:root=TWITTER 博客
Usage prefs:root=General&path=USAGE
VPN prefs:root=General&path=Network/VPN
Wallpaper prefs:root=Wallpaper 壁紙
Wi-Fi prefs:root=WIFI INTERNET_TETHERING 無(wú)線網(wǎng)
Internet_tethering prefs:root= INTERNET_TETHERING 網(wǎng)絡(luò)共享