Search code examples
iosxcodeuitextfieldstoryboardibaction

Attaching multiple UITextFileds to the same IBAction doesn't preserve triggering event


Using an Xcode 4.6 storyboard, I ctrl-drag from a UITextField to its viewController.h file and create an IBAction specifying the Editing Did Begin event. I then ctrl-drag from another UITextField to the same IBAction, but instead of using Editing Did Begin, it defaults to the Editing Did End event. Is there a way to change this to Editing Did Begin?


Solution

  • Try right-clicking (or ctrl-clicking) on the UITextField and manually dragging the proper action (the little plus sign) to the code in the .h file.