Search like Address Book?
Search like Address Book?
- Subject: Search like Address Book?
- From: "Mark's Studio" <email@hidden>
- Date: Sat, 11 Aug 2001 14:37:06 +0200
I have a tableview that i can search so it only shows the records that
match the search.(like Address Book)
I use two NSMutableArray, the mainArray has all the records, and the
displayArray only the records that match the search.
[displayArray removeAllObjects];
if(search mainArray)
[displayArray addObject:[mainArray objectAtIndex:i]]
but now the mainArray and the displayArray are out of sync.
so when i use selectedRow in the tableview for accessing the mainArray
its not the same as displayArray.
the displayArray is the datasource for the tableview, and when the
mainArray is changed the displayArray is updated.
and everything works fine except when they are out of sync.
what's the way to do this?
Peter Mark