okmr-d / DOAlertController

Simple Alert View written in Swift, which can be used as a UIAlertController. (AlertController/AlertView/ActionSheet)
MIT License
405 stars 68 forks source link

Cannot show another view controller by pressing button #27

Open shiaubo opened 7 years ago

shiaubo commented 7 years ago

It's a nice and easy library for alert controller. However, I have a question.

In my program, as I press the button, I want to show another view controller. So I use "performSegue" to do that. It works on UIAlertController. When I change to DOAlertController, the view didn't show up, but the code which I write in that view controller still appear in log. (It still prints what I want to show).

The error message is: Warning: Attempt to present <XXX.AnotherViewController: 0x101933400> on <DOAlertController: 0x101928a00> whose view is not in the window hierarchy!

I'm wondering if somebody can give me some directions, thanks a lot. :-)