Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8123497
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T06:12:00+00:00 2026-06-06T06:12:00+00:00

I am new to iPhone developer, I have 4 page in my Application, my

  • 0

I am new to iPhone developer,

I have 4 page in my Application, my Application is viewBasedApplication.

I made my 1st page(LicAppViewController) as RootViewController, here is my code.

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
    self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease]; 
    self.viewController = [[[LicAppViewController alloc] initWithNibName:@"LicAppViewController" bundle:nil] autorelease]; 

    UINavigationController *navigationController=[[UINavigationController alloc] initWithRootViewController:self.viewController];
    [self.window addSubview:navigationController.view];
    [self.window makeKeyAndVisible];
    return YES; 
}

on button click i am navigation to 2nd page(PlanPage)

-(void)btnClicked{

    PlanPage *viewController = [[PlanPage alloc]initWithNibName:@"PlanPage" bundle:nil];
    [UIView beginAnimations:@"Flip" context:nil]; 
    [UIView setAnimationDuration:0.7]; 
    [UIView setAnimationCurve:UIViewAnimationOptionCurveEaseInOut]; 
    [UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:self.navigationController.view cache:NO]; 
    [self.navigationController pushViewController:viewController animated:YES];
    [UIView commitAnimations];
    [viewController release];

}

till now it is working fine, but when i select a row in 2nd page it crashes my application, i want to navigate to 3rd page(DetailPlanPage), here is my code

    DetailPlanPage *nextController = [[DetailPlanPage alloc] initWithNibName:@"DetailPlanPage" bundle:nil];
    [self.navigationController presentModalViewController:nextController animated:TRUE];

but when i write, this line:

      [self.navigationController pushViewController:nextController animated:YES];

instead of:

       [self.navigationController presentModalViewController:nextController animated:TRUE];

it’s working fine. (I am not sure but crash of my application may be because of viewBased Application)

Thanks In Advance !

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T06:12:01+00:00Added an answer on June 6, 2026 at 6:12 am

    set rootview controller first

    remove that code

    [self.window addSubview:navigationController.view];
    

    and include

    self.window.rootViewController = navigationController;
    

    in present modal view controller u can try like this

        yourview *detailViewController = [[yourview alloc] initWithNibName:@"yourview" bundle:nil];
             UIBarButtonItem *doneButton = [[UIBarButtonItem alloc ] initWithBarButtonSystemItem:UIBarButtonSystemItemCancel target:self action:@selector(dismiss)];
         detailViewController.navigationItem.leftBarButtonItem = doneButton;
            UINavigationController *nav;
            nav=[[[UINavigationController alloc] initWithRootViewController:detailViewController] autorelease];
            [self presentModalViewController:nav animated:YES];
            [detailViewController release];
    [doneButton release];
    
    -(void) dismiss
    {
          [self dismissModalViewControllerAnimated:YES];
      }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am new to iPhone developer, I made epub reader and loaded each page
I am new to iPhone world. I have developed an application, which I would
I am very new to iPhone. I have developed two version of an application
fairly new iPhone developer here. Building an app to send RS232 commands to a
I am a new iPhone developer. By mistake I Have revoked my developer certificate.
New developer here. I'm making my first iPhone app. The app will display a
Greetings , I am a new developer in BlackBerry Application. I have been working
APPLICATION DESCRIPTION : I am a new iPhone developer. I am working on an
I am new iPhone developer, Can anybody suggest me what should i do here:
I am new developer on iPhone. My problem is that I have installed the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.