0

Currently trying to finish up making the login and registration form for my app. Registration works like how I want it to, but after working on the login screen I get the Thread 1: signal SIGABRT message on my AppDelegate.

AppDelegate File

So a little more detail about what I'm doing. I'm creating a main ViewController that gives the option to proceed to the login screen or the registration screen. I've set up my registration screen and it works fine, but I can't proceed to my login screen because it crashes when I press the login button on my main ViewController.

main ViewController

This is my first project and would appreciate any and all help thanks!

pacman
  • 1
  • 2
  • Check your login button action outlet if you have made that via storyboard. It would have been better if you have posted some code of your controller rather than a picture. – Rajan Maheshwari Oct 12 '16 at 16:34
  • Please post the crash Logs. We need to look at that to figure out what is causing the crash. – TheAppMentor Oct 12 '16 at 16:35
  • Any crash log in your console ? In the current format of the question we can't find/tell the reason of the crash – Midhun MP Oct 12 '16 at 16:36
  • Please see http://www.raywenderlich.com/10209/my-app-crashed-now-what-part-1 to learn how to debug a crash. Once you do that, update your question with actual relevant code (not as a picture but as copy and pasted text), error messages, and point out the exact line causing the issue. – rmaddy Oct 12 '16 at 16:41
  • @TheAppMentor Where do I need to go in order to obtain the crash logs? – pacman Oct 12 '16 at 16:46
  • You should see it in the console. In case you dont see the console use shift+command+c. You should see some information there. – TheAppMentor Oct 12 '16 at 16:49
  • @TheAppMentor Yup found it. Added it into the post. Thanks again! – pacman Oct 12 '16 at 17:05

1 Answers1

0

Here is the probable reason from the crash log.

  • Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[ setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key emailTxt.' * First throw call stack: ( 0 CoreFoundation 0x000000010c05634b

You might have created an outlet called "emailTxt". You might have then deleted it or changed its name.

To solve this, look at the elements you have in your storyboard, my guess is the login button or the email field might have two outlets. Find the one you no longer need and delete it.

In case you want to know how to find the outlets that UI element is connect to, just right click on it.

TheAppMentor
  • 1,091
  • 7
  • 14