This type of bug is divided into two categories:
One: When the view of your controller is loaded via Xib, but it is not bound to file ' owner in Xib, or the file ' owner is bound, but the view attribute inside the file's owner is not connected
Resolution: The first step:
:
Step Two:
Two: The second cause of the bug may be ignored by many people, when your controller's file name is similar to the name of a view you describe with Xib, is a controller is missing, this time will also be in operation when the collapse
For example
:
First of all to analyze: Ppvideoviewcontroller does not use Xib to describe, but if in the same project file, there is the same as the controller file name, but fewer controller filename, precisely the custom Ppviedeoview is xib to describe the ,
BUG: Then the problem is: when another controller wants to use the Ppvideoviewcontroller view, then the time to run will be reported with the same error
Cause: Because creating a controller we are generally ppvideoviewcontroller *VC = [Ppvideoviewcontroller alloc] init]; Init internal first will look for there is no ppvideoviewcontroller with the same xib file name, if not to find there is no with Ppvideoviewcontroller but less controller's xib file name, If you have one, load this xib!. There will be an error when loading, because ppvideoview.xib is not used to describe the Ppvideoviewcontroller controller view
It is used to describe the custom ppvideoview, so it will be an error at run time.
About '-[uiviewcontroller _loadviewfromnibnamed:bundle:] Loaded the "Xxxview" nib but the view outlet is not set. ' Cause of this bug