Action button in xcode not working.

I have made an IB outlet action button and the coding and the connections are perfectly alright but

when I run the macOSX build , and press the action buttons, nothing happenes.

Plz help !



THANKS !!!

MacBook Pro with Retina display, Mac OS X (10.0.x), mavericks

Posted on Aug 17, 2014 10:50 AM

Reply
9 replies

Aug 18, 2014 6:20 PM in response to Ishwar01

Just because you are not getting an error does not mean you do not have an error in your code. The fact that a simple IBAction is not working indicates a problem.


Have you done this sort of thing before or are you new at it? What have you done to try and fix the problem? If you create another button and connect it to a different method does it work?


The fact that you referred to the connection as an IBOutlet leads me to believe you did not connect the button to your code but you connected your code to the button. Ensure that the connection is an IBAction and not an IBOutlet.


If the connection is actually an IBAction are you sure the method is not being called? Perhaps it is but the code in the method is not working as you expect. Place a breakpoint at the first line in the IBAction and see if it is in fact being called.


Asking for help is fine but not supplying any information or telling us what you have tried makes it impossible to help.

Aug 19, 2014 11:39 AM in response to Ishwar01

according to the .m file the two methods reset and solve are not connected to the buttons. If they we you would have the dark circle next to the names as you have in the .h file. Something went wrong when you tried to attach the buttons to your code.


How did you attach them? What is the name of the m file and the h file? are there other files in the project?

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Action button in xcode not working.

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.