2

Can any one have any idea about this. I have a simple code which is not working properly. UIAlertController is transparent on iPhone 5s/s 8.4 and it crashes on iPhone 5s/s 9.3. Code below:

    let alert = UIAlertController(title: "title", message:"message" , preferredStyle: UIAlertControllerStyle.Alert)
    let action = UIAlertAction(title: "Close", style: UIAlertActionStyle.Default, handler: nil)
    alert.addAction(action)
    self.presentViewController(alert, animated: true, completion: nil)

Crash Message: Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'UIAlertController is expected to have a visual style during transitioning'

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
user942502
  • 111
  • 1
  • 7

0 Answers0