need to add pushviewcontroller in view based application
-(void)buttonClicked:(id)sender{
NSLog(@"welcome button");
testWebView = [[[TestWebView alloc]init] autorelease];
[self presentModalViewController:testW开发者_JS百科ebView animated:YES];
[testWebView test];
}
i trigger the buttonclicked and there i need to do PushViewController.
My application is view based application
@All
Thanks in advance./
You will need a navigation controller to perform the push operation. Go through the reference document on UINavigationcontroller
and this sample tutorial should get you started
Add a navigation controller in the app delegate and perform push operation through that navigation controller
-(void)buttonClicked:(id)sender
{
testWebView *srwmvc =[[testWebView alloc]init];
[self.navigationController pushViewController:srwmvc animated:TRUE];
}
Use your view's UIViewController
to access the navigation Controller
eg.
-(void)buttonClicked:(id)sender
{
testWebView *testWebView =[[testWebView alloc]init];
[myViewUIController.navigationController pushViewController:testWebView animated:TRUE];
}
精彩评论