ViewController respondsToSelector error solution, mvcviewcontroller

Source: Internet
Author: User

ViewController respondsToSelector error solution, mvcviewcontroller

Cause analysis: (analyze from others' blogs)
A public class or a control provided by the system has a delegate method. When the container class that creates this public control has been destroyed,
The service corresponding to this control is carried out in other run loop. when the control is destroyed or status notification is required
This problem occurs when the delegate pointer goes to the notification.

Problems encountered in the project:

Textview is in the focus state (the keyboard pops up), and then click the cancel button to pop the current uiviewcontroller. At this time, the keyboard recycling operation of textview is triggered first, in the keyboard reclaim method, the contentOffset of the scrollview is reset. When the contentOffset of the scrollview is set, the delegate (VC) call is triggered continuously, and the VC has been released, so there was a crash. Set the delegate to null in dealloc (the delegate of iOS6 tableview should also be empty)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.