I used LMAlertView to custom the AlertView which shown in GIF http://imgur.com/a/Bu8PR
Q: How to dismiss this alertview on outside tap?
I tried some solution shown in Dismiss modal view form sheet controller on outside tap.
The AlertView dismissed with code but the view also lost control and get the error message below
Unbalanced calls to begin/end appearance transitions for <LMEmbeddedViewController: 0x12fd03bf0>.
For the above error i tried to set [self dismissViewControllerAnimated:YES completion:nil];
animated form YES to NO or use dispatch_async(dispatch_get_main_queue(), ^{
to contain [self dismissViewControllerAnimated:YES completion:nil];
, but still didn't work.
Solution:
[[self presentingViewController] dismissViewControllerAnimated:YES completion:nil];