你好,我有一個小問題。聲明選擇器presentviewcontroller
我得到了一個項目的應用程序,但它是一個有點舊的應用程序(IOS 7)。
我在網上看到如何更新UIAlertController使用舊版UIAlertView的INSTEAD。
if (error.code) {
cancelBlock = block;
UIAlertController *alert = [UIAlertController alertControllerWithTitle: @"Message"
message: @"Peripheral Disconnected with Error"
preferredStyle: UIAlertControllerStyleAlert];
UIAlertAction *alertAction = [UIAlertAction actionWithTitle: @"OK"
style: UIAlertActionStyleDestructive
handler: ^(UIAlertAction *action) {
NSLog(@"OK");
}];
[alert addAction: alertAction];
[self presentViewController: controller animated: YES completion: nil];
/* UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Peripheral Disconnected with Error"
message:error.description
delegate:self
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[alert show];*/
,我感到我不明白的錯誤:
爲 'RFduino' 不可見@interface聲明的選擇 'presentViewController:動畫:完成'
是什麼RFduino您在項目 – techloverr