0

I created a NSObject called profile which contains user's first name, last name and display name. All these properties are another NSObject I created which call FieldString. The FieldString has a getter function to get the NSString for names.

So, How to search a user named Jason to use NSPredicate or other methods?

  • 1
    Did you try any code so far? – Asdrubal Aug 02 '16 at 18:55
  • I am not very good at NSPredicate. I tried some pretty stupid thing like [NSPredicate predicateWithFormat:@"[profileFirstName get] contains[cd] %@", searchTerm]. It is not working. –  Aug 02 '16 at 19:01
  • http://stackoverflow.com/questions/24176605/using-predicate-in-swift give this a try – Asdrubal Aug 02 '16 at 19:02

0 Answers0