ios - How to display my search results in UICollectionView -


i have uiview has 2 textfield,two labels ,uicollectionview, , 1 search bar.i want add searchdisplaycontroller , searchbar uiview.

i have linked datasources , delegate search.

searchbar=[uisearchbar new]; searchdisplaycontroller=[[uisearchdisplaycontroller alloc]initwithsearchbar:searchbar contentscontroller:self]; searchdisplaycontroller.delegate=self; searchdisplaycontroller.searchresultsdelegate=self; searchdisplaycontroller.searchresultsdatasource=self; [self.view addsubview:searchbar]; 

my problem searchdisplaycontroller has results in searchresultstableview , can populated tableview delegates have uicollectionview.

how can display search results in collection view delegate methods? view looks this: enter image description here

with uisearchdisplaycontroller, simple: create uisearchbar , add custom uicollectionview section header, initialize uisearchdisplaycontroller search bar

have @ answer: https://stackoverflow.com/a/24992762/2082569


Comments

Popular posts from this blog

javascript - AngularJS custom datepicker directive -

javascript - jQuery date picker - Disable dates after the selection from the first date picker -