Quiz App Crash (XCode 4.1)


#1

Hi, I have been reading through some of the threads here and from what I understand, there have been some issues with the Quiz app and the latest version of XCode. I am running into a problem with it as well but I happen to be using XCode 4.1 which, from what I understand, should be fully supported by the 2nd edition of this book. My particular problem is that I compile the app just fine (no errors) but when I run it, the simulator launches and Xcode reports a crash with the app. However, if I close XCode, the simulator window remains running and I can use the app just fine - I cannot run the app on the simulator while Xcode is running. What gives?!

Looking at the debug navigator, breakpoints, it shows me 2.

-One pointing to QuizAppDelegate.m, points to --> @implementation QuizAppDelegate
-Second pointing to main.m, points to --> int retVal = UIApplicationMain(argc, argv, nil, nil); (says thread 1: stopped at breakpoint 1)

I am very new to XCode so if the above isnt enough and you can tell me how I can trace additional debugging info, I’d be happy to do so.

Thanks in advance for any help you can provide. I am liking the book a lot but I am dissapointed that the very first app is causing this problem, specially when that I am seeing no issues with the code whatsoever.

I have tried turning off AutoComplete on the iOS simulator as suggested in other threads but the issue remains


#2

Hi, can you run your application again and post the text inside debug area here?
It should appear in Xcode after clicking the Run-Button.
You can also try to clean your Project (Click on “Products” and then on “Clean” in the Xcode-Menu).
Delete the App from the Simulator and click the Run-Button again.
Maybe this fixes the error.


#3

Hey Rockit, I figured it out. Looks like my inexperience with the development environment was the culprit I had a couple of syntax issue with the code at first which resulted in 2 breaks when running it the first time. After fixing that I guess xcode kept showing the breaks when running the app, though it did show breaks resolved in the debug log. This was somehow halting the app from running. After I clicked ‘clean breaks’ it worked. does that make sense?

Thanks again.