9 Replies
      Latest reply on Apr 5, 2020 11:13 AM by PBK
      ace.neerav Level 1 Level 1 (0 points)

        I wrote the following code to do so but I get a runtime exception saying

         

         this class is not key value coding-compliant for the key date.

         

        Here is my code...

         

         NSSortDescriptor *sortDescriptor = [[NSSortDescriptor alloc] initWithKey:@"date" ascending:TRUE];
                        [historyDateArray sortUsingDescriptors:[NSArray arrayWithObject:sortDescriptor]];
        

        What am I doing wrong?

         

        History date array has all NSDates

         

        Neerav