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 9117731
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T04:57:56+00:00 2026-06-17T04:57:56+00:00

I am developing an iphone application where you log in a server and after

  • 0

I am developing an iphone application where you log in a server and after you get validation my app moves you to another viewcontroller where you can use a button to send your gps location. For some reason when I press a button in my next viewcontroller I get this error :

Administrator[3148:c07] -[UIViewController SendGPS:]: unrecognized selector sent to instance 0x88b58d0
2013-01-08 16:01:21.662 Administrator[3148:c07] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIViewController SendGPS:]: unrecognized selector sent to instance 0x88b58d0'

If I apply my gps code-buttons in a single viewcontroller it turns out to work fine but when I use my app with the two viewcontrollers when the first one redirects you to the second one (if only you log in to the server) I get this mistake.I move to the second viewcontroller through a condition where I check the response from the server. This is the code which i use to change viewcontrollers :

NSString *compare = [NSString stringWithFormat:@"true"];

    if ( [compare isEqualToString:string])  {

        UIViewController* FourthViewController = [[UIViewController alloc] initWithNibName:@"FourthViewController" bundle:[NSBundle mainBundle]];
        [self.view addSubview:FourthViewController.view];   }
    else
        NSLog(@"validation not complete");

and this is my button where i use an NSTimer:

-(IBAction)SendGPS:(id)sender
 {
     Timer= [NSTimer scheduledTimerWithTimeInterval:30.0 target:self  selector:@selector(requestIt) userInfo:nil repeats:YES];
 }

Any thoughts? 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-17T04:57:57+00:00Added an answer on June 17, 2026 at 4:57 am

    The incorrect part of your code is obvious, this is how you initialize your view controller:

        UIViewController* FourthViewController = [[UIViewController alloc] initWithNibName:@"FourthViewController" bundle:[NSBundle mainBundle]];
    

    And that is creating a new view controller object, fresh from Apple’s code, that has no Chuck Norris’ idea what the method SendGPS: is. Because you obviously created a new view controller subclass called ‘FourthViewController‘ that implements SendGPS: in your Xcode project. You are creating an instance called ‘FourthViewController‘ but it doesn’t actually point to that class, its a UIViewController class as you specified.

    The correct code should be:

        FourthViewController *myFourthViewController = [[FourthViewController alloc] initWithNibName:@"FourthViewController" bundle:[NSBundle mainBundle]];
    

    You really need to figure it out, I don’t think you understand Objective-C, pick up a book, get reading, and do it right!

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

Sidebar

Related Questions

I m developing an iPhone app which includes facebook wall posting.After log in, I
I am developing an iPhone application that retrieves the data from remote MySQL server.
I am developing an iPhone application and I use HTML to display formatted text.
I'm developing an iPhone application that makes heavy use of Core Data, primarily for
i am developing on iPhone application. in this app i have 4 different views.
I am developing an iPhone application which mainly makes use of the Address Book
I am developing a iPhone application in which i want to get notification in
I am developing iPhone application using SQLite . I decided to use fmdb .
I am developing one Iphone application using jquery mobile + HTML5. I can check
I'm developing an iPhone application with Xcode 4.5.2, and when I run the app

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.