Guest User

Untitled

a guest
Feb 18th, 2019
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. let alertController = UIAlertController(title: " ", message: message, preferredStyle: .alert)
  2. let action1 = UIAlertAction(title: "OK", style: .default) { (action) in
  3. print("Default is pressed.....")
  4. }
  5. let action2 = UIAlertAction(title: "Cancel", style: .cancel) { (action) in
  6. print("Cancel is pressed......")
  7. }
  8. let action3 = UIAlertAction(title: "Click new", style: .default) { (action) in
  9. print("Destructive is pressed....")
  10.  
  11. }
  12. alertController.addAction(action1)
  13. alertController.addAction(action2)
  14. alertController.addAction(action3)
  15.  
  16. self.present(alertController, animated: true, completion: nil)
Add Comment
Please, Sign In to add comment