I'm a newbie programmer and I have played around with the SDK for a while. How do you create a homepage that has a button that will bring you to another view (the content of the app)??? If you know can you list the steps in order or link a tutorial site (It woul be awesome if the steps had code with it I needed). Thanks!
views:
92answers:
1
A:
I would recommend getting a good book on iPhone programming. What you want to do is set up a UINavigationController, add the button to the first view, set the action of the button's touchUpInside to call the showContent method. Then implement the showContent method to push the Content view controller.
- (IBAction) showContent{
ContentViewController *myContentController = [[ContentViewController alloc] init];
myContentController.title = @"Content";
[self.navigationController pushViewController:myContentController animated:YES];
[myContentController release];
}
Have a read up on the documentation for pushViewController and UINavigationControllers, then follow this tutorial.
Jack
2010-01-31 12:58:40
Ok thanks. The site is just what I needed
Da Coder
2010-01-31 16:19:40
No worries, there are quite a few tutorials on the topic. My recommendation is that when you get taught something in a tutorial, read up in the documentation about a couple of the things that you learned about. Once you understand how to use the documentation, the world is your oyster.
Jack
2010-01-31 16:34:49
How can you do it without having cells and stuff?
Da Coder
2010-01-31 23:42:35
If you read my post it explains roughly what to do. Try working through that step by step. If you get stuck, post a new question. If you try and work through a good book, you will be amazed at how quickly things progress. 'Beginning iPhone Development' is a good start.
Jack
2010-02-01 12:15:34
Here is another simple tutorial, work through it and try and merge it with what you have already. The code above might also be helpful.http://knol.google.com/k/iphone-sdk-helloworld
Jack
2010-02-01 12:25:36
Thanks Again. Your awesome. ;-)
Da Coder
2010-02-01 23:29:16