I have an application and I continue to get the log output: "Unknown class ingredientLabel in Interface Builder File." ...when I load a specific view.
The ingredientLabel is a label I created in the view. Here is the relevant code:
in DetailViewController.h:
@interface QuickGroceryDetailViewController : UIViewController
{
UILabel *ingredientLabel;
}
@property (strong, nonatomic) IBOutlet UILabel *ingredientLabel;
in DetailViewController.m:
@synthesize ingredientLabel = _detailDescriptionLabel;
- (void)setDetailItem:(id)newDetailItem
{
if (_detailItem != newDetailItem) {
_detailItem = newDetailItem;
// Update the view.
[self configureView];
}
}
- (void)configureView
{
// Update the user interface for the detail item.
if (self.detailItem) {
self.ingredientLabel.text = [self.detailItem description];
}
}
No error occurs, and the app runs fine, but I wanted to know why this error is occurring as it could cause problems down the line. Thank you.