dalearyous
[H]ard|Gawd
- Joined
- Jun 21, 2008
- Messages
- 1,922
so i have an array that is currently searchable. when you load the app it loads up the information in a tableview with a list of the (in my case) names in the array. if you click on any one of the names it loads the correct detail view. the search works just fine too. when you begin typing it narrows down the searchs and displays what is left below the search bar. cool. however, lets say there are three names: Bob, Carl, Devin. if you start typing D, the search narrows it down to just Devin. if you click on Devin it doesn't load Devin's detail view, it loads Bob's because bob is the first one in the array. any idea how to fix this? i would be happy to send my project to someone or provide code snippets here
from what i have read i think that i am not retaining the original value of indexPath.row (prior to the search). cause when i do the search it uses indexPath.row again but now any of the three is on the first line...hence row 0. (because the search has narrowed it down to just 1 item which is at position 0 now)
make sense?
from what i have read i think that i am not retaining the original value of indexPath.row (prior to the search). cause when i do the search it uses indexPath.row again but now any of the three is on the first line...hence row 0. (because the search has narrowed it down to just 1 item which is at position 0 now)
make sense?
Last edited: