Assertion Failure in Void _Uiperformresizeoftextviewfortextcontainer

Assertion failure in void _UIPerformResizeOfTextViewForTextContainer

Well, the exception reason gives the problem away; you should run this code on the main thread. Try enclosing the view creation and nib loading using dispatch_sync or dispatch_async and passing the main queue using dispatch_get_main_queue().

Dismissin Alert in async complection Handler throws exception

Make sure your completion handler is called on the main thread. All UI-related operations must be performed on the main thread. You can wrap the call with dispatch_async:

dispatch_async(dispatch_get_main_queue(), ^{
alert1.dismissViewControllerAnimated(true, completion: nil)
});


Related Topics



Leave a reply



Submit