UISearchBar is hidding in ipad where as in iphone it is working properly
I have designed an application for iphone/ipad. My problem is that I am using single RootViewController for showing Cate开发者_开发问答gory and Subcategory.
//Pop me to RootViewController Category Section From SubCategory in iphone/ipad
[self.navigationController popViewControllerAnimated: YES];
But in ipad my searchbar get hidden under the navigation bar.Dont know what to do.want to show my searchbar at the same place as it was placed beneath navigation bar ContentOffset is 44.
-(void)viewWillAppear
Just got The Solution
First when the canel button is pressed reload the table [self.tableView reloadData]; then at which index in the table you wanna to go from secondviewcontroller to firstviewcontroller.
NSIndexPath *indexPath = [NSIndexPath indexPathForRow:0 inSection:0];
Necessary if selecting row in -viewDidLoad
[self.tableView selectRowAtIndexPath: indexPath animated: YES scrollPosition: UITableViewScrollPositionTop];
精彩评论