If you use NChartView as IBOutlet, xcode can generate some problems like
- 'Unknown class NChartView in Interface Builder file'
- '-[UIView chart]: unrecognized selector sent to instance'
The problem is that it's not so straightforward to link storyboard with the custom view. The app does not load third-party framework (for example, NChart3D) before creating storyboard, so at the time storyboard is created there are no symbols from NChart3D available. This is how iOS is organized right now.
The workaround is to subclass NChartView with you own class and use this class in storyboard:
@interface MyChartView : NChartView @end @implementation MyChartView @end @interface ViewController : UIViewController @property (strong, nonatomic) IBOutlet MyChartView *chartView; @end
Also don't forget that storyboard creates and loads view by itself and you don't need to implement -(void)loadView.
You just need to customize chart in -(void)viewDidLoad method.