I am a neewbie in iPhone develement, i am trying to create single view application using xcode 4.2 , i want to move from one view to another view . Is there any way to push view from one to other without using storyboard ?
1 Answer
MySub1ViewController *mySub1ViewController = [[MySub1ViewController alloc] init];
//Push it to the top of the navigation controllers stack
[[self navigationController] pushViewController:mySub1ViewController animated:YES];
//Pop viewController from the view stack
[[self navigationController] popViewControllerAnimated:(BOOL)YES];
For more check this tutorial
4 Comments
rohan-patel
Does it work on XCode 4.2 ??Because the tutorial link you gave is seems to be coded in Xcode 4.0 or below version. Kindly throw light on that.
Srikar Appalaraju
yes it works in xcode4.2. I myself use it in xcode4.3. actually its not xcode that you need to worry about but the iOS version that your are using & yes this works in ios4 & ios5...
rohan-patel
Ok. my team mates who works on Xcode 4.2 requests me to create window based app in my Xcode 4.0.1 and send them after that so they continue proj work from there as there is no option for Window based Project in XCode 4.2.
Srikar Appalaraju
yes that should work.Again Xcode is the IDE. that versioning apart, iOS versioning is whats more relavent. Also if you think my answer has in anyway helped you, please upvote :)