I am using UISearchDisplayController to pull in results from a webservice but I want to be able to search even if the search bar's text is empty. It seems like results are only being pulled in if this is not empty. How do I update & show the results tableview by only scope?
A:
For that you can put the condition when the scope button is changed
if([searchBar.text length])
{
//CALL FOR QUERY ACCORDING TO TEXT IN SEARCHBOX
}
else
{
//CALL THE QUERY AS PER CHANGE IN SCOPE
}
hAPPY cODING...
Suriya
2010-09-30 08:23:09
A:
Use the - (void)searchDisplayControllerDidBeginSearch:(UISearchDisplayController *)controller UISearchDisplayControllerDelegate to search and then reload the searchResultsTableView (UISearchDisplayController)
Sander Backus
2010-09-30 12:23:41
Thanks but the problem isn't that I can initiate the search, it's that the resultsTableView will not display unless you have something entered in the UISearchBar.
Kyle Decot
2010-09-30 18:24:43