Connect object in .xib to existing IBAction
I am quite new to iOS Programming.
This is my question:
I want to connect a new object to an existing IBAction method. For example, I want to buttons to perform the same function.
But when I “control-drag” it, it will always ask me to insert as a new method. How can I add to the existing one instead of creating a new one?
Snapshot in XCode
- How do I name and link an IBAction button created in a storyboard
- How to define which button pressed if they both have same IBAction?
- NSButton Multiple clicks
- Using IBAction Buttons to Zoom MapView
- Is @IBAction just a syntax in Swift or does @Something mean a particular thing in Swift?
- UIButton not responding after animation
Solutions Collect From Internet About “Connect object in .xib to existing IBAction”
xib editor, you can see the
File's Owner. Just right click the button to see the black popup as shown in the image below. Then drag the empty dot to the
File's Owner tab and release the drag action. You’ll see a popup of all existing
IBActions. Select the one you want and it’ll be added as a selector to your button. You can do this for as many buttons as you want.
- How to use CMAltitudeHandler in Swift?
- How to insert records in external database with objective-C
- Segmentation Fault 11 on upgrading to Swift 2.0
- dismissViewControllerAnimated VS popViewControllerAnimated
- Making HTTPS request in iOS 9 with self-signed certificate
- pfuser with pointer not getting data back
- How to mute/unmute audio when playing video using MPMoviePlayerController?
- Can I restrict my iPhone app from being used by iPhone3G's?
- Using Facebook Graph API on iOS
- How do you tell what object is being touched in touchesBegan?
- UINavigationItem centering the title
- Opens apple maps app from ios app with directions
- Adding constraint to a UITableVIew headerview
- NSPredicate: filtering objects by day of NSDate property
- XCode Server: Opening import file for module 'MobileCoreServices': Permission denied