zoukankan      html  css  js  c++  java
  • iOS

    UIAlertController : UIViewController

     UIAlertController *alertContr = [UIAlertController alertControllerWithTitle:@"提示信息" message:@"確定要註銷?" preferredStyle:UIAlertControllerStyleAlert];

        UIAlertAction *okAction = [UIAlertAction actionWithTitle:@"確定" style:UIAlertActionStyleDefault handler:^(UIAlertAction * _Nonnull action) {

         //确定

            [self performSegueWithIdentifier:@"BackLoginView" sender:nil];

        }];

        

        UIAlertAction *cancelAction = [UIAlertAction actionWithTitle:@"取消" style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {

            //取消

         

        }];

        

        //添加操作(順序:上下順序)

        [alertContr addAction:cancelAction];

        [alertContr addAction:okAction];

        

        //呈現警告視圖

        //[self presentViewController:alertContr animated:YES completion:nil];

        [aletContr show];

    喜欢请赞赏一下啦^_^

    微信赞赏

    支付宝赞赏

  • 相关阅读:
    JS笔记之第七天
    JS笔记之第六天
    JS笔记之第五天
    JS笔记之第四天
    JS笔记之第三天
    JS笔记之第二天
    JS笔记之第一天
    PHP文件上传
    bit、Byte、bps、Bps、pps、Gbps的单位的说明及换算
    Redis初级安装及使用
  • 原文地址:https://www.cnblogs.com/share-iOS/p/6426908.html
Copyright © 2011-2022 走看看