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

  • Home
  • SEARCH
  • 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 9094279
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T23:18:50+00:00 2026-06-16T23:18:50+00:00

I am facing a strange problem in iOS iPad app. My application is crashing

  • 0

I am facing a strange problem in iOS iPad app. My application is crashing when I map a UIButton to an IBAction with touch up inside event. The error I get in the console is like
Unrecognized selector NSInvalidArgumentException.

By the way all the view controllers in my project have the same problem. The view controllers are mapped to a tab bar controller.

I have created this project by dragging and dropping all the files from another project. The dragged files are placed properly in the current project, no problem with that. Will this cause problem?

I was not able to figure out what went wrong.

Thanks

  • 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-16T23:18:51+00:00Added an answer on June 16, 2026 at 11:18 pm

    Thanks for your answers. I have resolved the problem.

    Actual Problem:

    1. My project is with ARC.
    2. Actually i am navigating to a new view from one view to other by adding it as subview by clicking a button with IBAction as below,

      -(IBAction)signInAndGoToFrameworkView :(id)sender{  
      
      MyViewController myViewController  = [[MyViewController alloc] initWithNibName:@"MyViewController " bundle:nil];
      [self.view addSubview:myViewController.view];
      
      }
      

    3 . As the project is with ARC, the object myViewController is released since this is a local variable. So when i press back button to do

       [self.view removeFromSuperview]; 
    

    the app was getting crashed.

    Solution:

    So when i just declared MyViewController myViewController in .h file and also given @property and @synthesize. Then changed the IBAction with,

       -(IBAction)signInAndGoToFrameworkView :(id)sender{  
    
        myViewController  = [[MyViewController alloc] initWithNibName:@"MyViewController " bundle:nil];
        [self.view addSubview:myViewController.view];
    
        }
    

    Now the problem solved.

    Thanks.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am facing a strange problem. my app shows current location on map when
since today im facing a strange problem. When i start my app in my
I am facing a strange problem with AVAudioRecorder. In my application i need to
I am facing a strange problem. My app relies on a double conversion: currency
I'm facing a strange problem when deploying my application to the production server. I've
I am facing a strange problem with p:autoComplete, I get following error java.lang.NumberFormatException: For
I am facing quite strange problem. Application ~80.Mb Testing on simulator using Allocations Instrument,
I am facing a strange problem. My app works fine in 2.1 (emulator +
I am facing a strange problem while running my application. I have a class
I am facing a strange problem for last 2 days. My gridview's rowcommand event

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.