Okay, I have an Book Object Class. That has Book.name and Book.id as extensions. Book.name being NSString. Which is what should be searchable and listed in UITableView.
NSMutableArray *matchingSymptomsArray = [[NSMutableArray alloc] initWithCapacity:50];
for(NSMutableArray *letterArray in DataArray){
for(Book *bk in letterArray){ //Heres the ERROR
NSLog(@"Uptil NEW");
if([bk matchesSearchString:searchString]){
//I couldnt reach here, according to debugging and Logs//
[matchingSymptomsArray addObject:bk];
}
}
}
DataArray is where all the Books are held.. more than a hundred. Its the main datasource for the UITableView. I'm trying to search and match each letter of the string with the Book.name, but even before I can begin, I cant do the for(Book *bk in LetterArray) //producing the error..
What seems to be the problem?
This is the error in console ** -[Book countByEnumeratingWithState:objects:count:]: unrecognized selector sent to instance 0x55c110 2009-09-29 06:17:41.073 Smart Diagnosis[3897:20b] * Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[Book countByEnumeratingWithState:objects:count:]: unrecognized selector sent to instance 0x55c110'*
Any work arounds??
thanks for your help :)