Quote:
Originally Posted by Georg
Submit again,,,,,
|
-(IBAction)FirstView;
{
if (self.optionMenu == nil) {
OptionViewController *optionMenuView = [[OptionViewController alloc] initWithNibName:@"OptionViewController" bundle:nil];
self.optionMenu = optionMenuView;
[self.view insertSubview

ptionMenuView.view atIndex:99];
[optionMenuView release];
} else {
[optionMenu.view removeFromSuperview];
}
[self.view removeFromSuperview];
}
The problem is, the subview disappeared because of the last line [self.view remove FromSuperview], how can I keep the last view on the screen and remove the last-1 view?