美文网首页
UIAlertController

UIAlertController

作者: 纯阳子_ | 来源:发表于2017-08-14 14:52 被阅读2次

    UIAlertController *alertController = [UIAlertController alertControllerWithTitle:@"" message:@"确定删除我嘛?" preferredStyle:UIAlertControllerStyleAlert];

    UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"确定" style:UIAlertActionStyleDefault handler:^(UIAlertAction *action){
    
    }];
    
    UIAlertAction *cancelAction = [UIAlertAction actionWithTitle:@"取消" style:UIAlertActionStyleDefault handler:^(UIAlertAction *action){
    
    }];
    
    [alertController addAction:okAction];
    [alertController addAction: cancelAction];
    
    [self presentViewController:alertController animated:YES completion:nil];

    相关文章

      网友评论

          本文标题:UIAlertController

          本文链接:https://www.haomeiwen.com/subject/ibeurxtx.html