Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

fergusjk

macrumors member
Original poster
I have a tabbar app that is using a UITableView in one of the tabs. When the user selects one of the rows I want a new view to show up.

I am not currently using a Navigation bar as there is already plenty of competition for screen real estate in that view.

I have the following code
- (void)tableView🙁UITableView *)tableView didSelectRowAtIndexPath🙁NSIndexPath *)indexPath {
NSLog(@"IN HERE!!!!");
NSLog(@"indexPathSection=%d", indexPath.section);
NSLog(@"indexPathRow=%d", indexPath.row);

ViewWithFurtherDetail *detailViewController = [[ViewWithFurtherDetail alloc] initWithNibName😡"ViewWithFurtherDetail" bundle:nil];

[self presentModalViewController:detailViewController animated:YES];
[detailViewController release];

}

This works but it animates up from the bottom rather from the right.

Two questions.
1. How do I get this to animate from the right?
2. How do I 'get back' to the UITableView view once the new view is established? I'm probably going to have a small button with title 'back' which the user can press but what is the actual code required to return to the previous view?
 
I ultimately went with the Navigation controller on top of the tab bar, therefore I have a navigation view as one of my tabs.

It was relatively easy to implement actually. If anyone is interested then type in "tabbar navigation" to youtube and there are a few good tutorials on the matter. 😀
 
If you feel your screen real estate is precious, you might want to consider hiding the navigation bar until it's needed.
 
If you feel your screen real estate is precious, you might want to consider hiding the navigation bar until it's needed.

Good point Dejo, but now that I see it there it looks rather neat 😀
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.