Sorting by date format in iphone
问题 I am new to iphone development.I am sorting a mutable array with respect to date.But it is sorting Using the date parameter consider it as string.I want to sort it by date.How can i achieve that .Please help me out. NSSortDescriptor *descriptor = [[NSSortDescriptor alloc] initWithKey:@"pubDate" ascending:YES]; [stories sortUsingDescriptors:[NSArray arrayWithObjects:descriptor,nil]]; Can i use selectors? if so how should i use it?.Thanks. 回答1: -(void)parser:(NSXMLParser *)parser