I have the following initWithCoder implementation which depends on the callback of the datasource method. But somehow the datasource is nil and the datasource methods aren't called. I'm using a storyboard and therefor have overwritten the initWithCoder-Method.
- (id)initWithCoder:(NSCoder *)aDecoder {
self = [super initWithCoder:aDecoder];
if (self) {
NSUInteger rows = 0;
NSUInteger columns = 0;
if (self.dataSource && [self.dataSource respondsToSelector:@selector(numberOfHeaderRowsInSpreadSheetView:)]) {
rows = [self.dataSource numberOfHeaderRowsInSpreadSheetView:self];
}
if (self.dataSource && [self.dataSource respondsToSelector:@selector(numberOfHeaderColumnsInSpreadSheetView:)]) {
columns = [self.dataSource numberOfHeaderColumnsInSpreadSheetView:self];
}
[self setupWithNumberOfHeaderRows:rows numberOfHeaderColumns:columns];
}
return self;
}
Does anybody has a clue?
Thanks in advance.