Skip navigation

iPhone 101 guide error

12667 Views 25 Replies Latest reply: May 5, 2012 10:22 AM by andyzoom01 RSS
1 2 Previous Next
QuadraQuack Level 1 Level 1 (0 points)
Currently Being Moderated
May 12, 2011 9:32 PM

Hello,

 

I'm following the "Your First iOS Application" (a.k.a. iPhone 101) and under Chapter 5 on page 40 (of the PDF) where it instructs me to create an action for the button in the nib file named "changeGreeting", I'm getting the following error:

 

Could not insert new action connection: No @implementation found for the class "MyViewController"

 

I'm not a programming noob, but I'm new to iOS/Mac programming (I've been developing Windows applications for almost 11 years). I followed the guide very carefully up to this point and everything was working until this.

 

I'm using the latest version of Xcode (4.02).

 

It seems to be complaining that it isn't aware of MyViewController, but I don't understand why. Any help would be most appreciated. Thanks.

  • K T Level 7 Level 7 (23,215 points)
    Currently Being Moderated
    May 12, 2011 11:18 PM (in response to QuadraQuack)

    Check your code for uses of MyViewController versus myViewController - see this thread:

    https://discussions.apple.com/thread/2396194?threadID=2396194&tstart=0

  • Squench Calculating status...
    Currently Being Moderated
    May 14, 2011 8:00 PM (in response to K T)

    I am also receiving the same error. The thread supplied did not resolve my problem.

     

    I am very keen to find a solution, any help is appreciated.

     

    Thank you!

  • thnbgr Calculating status...
    Currently Being Moderated
    May 16, 2011 3:16 PM (in response to Squench)

    Got the same error.  Any help or update?

  • TTGator Calculating status...
    Currently Being Moderated
    Jun 5, 2011 8:56 AM (in response to QuadraQuack)

    Same problem here.  No solutions yet I assume?

  • TTGator Level 1 Level 1 (0 points)
    Currently Being Moderated
    Jun 6, 2011 10:01 AM (in response to QuadraQuack)

    Well I'm not sure exactly what caused this, but I can tell you what I did that possibly created the problem.  I created a new->file that was a ViewController and made some changes.  Then I removed the 3 files that were generated for me because I had just created it to show someone how easy it was to create a UI.  The next day I created the ViewController again with the SAME NAME, and the problem we're talking about started happening.  Did anyone else do this same thing?

     

    Anyway, I created another new ViewController with a different name, and everything seems to work just fine.  So maybe it's an XCode 4.02 bug if you delete then recreate using the same filename? Just a theory.

     

    -Aaron

  • james957 Calculating status...
    Currently Being Moderated
    Jun 26, 2011 11:26 AM (in response to TTGator)

    I'm having the same problem.  I had deleted and re-created new files with the same name as well.

  • frenchef Calculating status...
    Currently Being Moderated
    Jun 29, 2011 1:42 PM (in response to QuadraQuack)

    Hi,

     

    Im going through the steps of the tutorial and ran into this exact problem.

     

    I was able to fix the problem by exiting from Xcode and restarting it.

     

    On restart of Xcode everything worked fine.

     

    A funny little thing in Xcode i guess.

  • danielson317 Calculating status...
    Currently Being Moderated
    Jul 1, 2011 11:50 AM (in response to QuadraQuack)

    I spent about 20 min debugging this and found that I had an error in the header file that said "incomplete implementation" on my @implementation line. I finally fixed it by moving the bracked on the @intervace line

    From:

     

    @interface MyViewController : UIViewController {

    }

     

    To:

     

    @interface MyViewController : UIViewController

    {

    }

     

    It would appear xcode is a bit sensative to bracket placement.

  • professortodd Calculating status...
    Currently Being Moderated
    Jul 11, 2011 1:14 PM (in response to QuadraQuack)

    I had this same problem and I solved it by saving my header file MyViewController.h

  • brianvaughn Calculating status...
    Currently Being Moderated
    Jul 21, 2011 11:13 AM (in response to QuadraQuack)

    Any update here? I'm not reading through the tutorial that others on this thread seem to be following, but I've tried the various "fixes" mentioned in this thread and I'm still having no luck.

  • Richard Downey Calculating status...
    Currently Being Moderated
    Jul 29, 2011 4:34 AM (in response to QuadraQuack)

    I solved this problem by exiting and restarting XCode and waiting for it to index all of the files in my project before trying to add my new outlet.  I think that XCode wasn't able to index the files for some reason (simulator running maybe?)

1 2 Previous Next

Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)

Legend

  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.