【发布时间】:2012-02-25 05:45:17
【问题描述】:
当我点击下面的按钮informationBtn_clicked 时,我遇到了一个奇怪的问题。 InformationView来了。
主视图
-(IBAction)informationBtn_clicked:(id)sender{
InformationView *obj_Info=[[InformationView alloc] initWithNibName:@"InformationView" bundle:nil];
UINavigationController *navigationObj = [[UINavigationController alloc] initWithRootViewController:obj_Info];
[self.navigationController presentModalViewController:navigationObj animated:YES];
}
下一个视图
在后面的 btn 点击关闭视图控制器后;
-(void)btnBackClicked:(id)sender{
[self dismissModalViewControllerAnimated:YES];
}
在这里,我的问题是当我关闭 NextView 时,再次调用主视图 viewDidLoad 方法。我的项目在 iOS 5 中运行,我正在使用 ARC。
我正在检查一种方法,即发布obj_Info,但结果相同,请帮助我,我的英语很差,试着理解我。
【问题讨论】:
-
这个链接可以帮助你..stackoverflow.com/questions/5462481/…
标签: iphone objective-c ios uiview