ios - Filtered uitableview doesn't call didSelectRowAtIndexPath when clicked on one of the results -


i'm having searchbar on tableview. works except when results displayed. want click on result , segue.

now click on , didselectrowatindexpath isn't called.

this uibar , searchcontroller:

_searchbar = [[uisearchbar alloc] initwithframe:cgrectmake(0, 0, 320, 44)]; _searchbar.delegate = self;  searchdisplaycontroller = [[uisearchdisplaycontroller alloc] initwithsearchbar:_searchbar contentscontroller:self]; searchdisplaycontroller.delegate = self; searchdisplaycontroller.searchresultsdatasource = self;  self.tableview.tableheaderview = _searchbar; 

implemented delegate:

- (void)tableview:(uitableview *)tableview didselectrowatindexpath:(nsindexpath *)indexpath 

but not called when click on 1 of results.

do need add delegate?

you forgot set delegate of search results table view, searchdisplaycontroller.searchresultsdatasource = self;

searchdisplaycontroller.searchresultstableview.delegate = self; 

Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -