Instance Method


Returns the actions performed on a target object when the specified event occurs.


- (NSArray<NSString *> *)actionsForTarget:(id)target forControlEvent:(UIControlEvents)controlEvent;



The target object—that is, an object that has an action method associated with this control. You must pass an explicit object for this method to return a meaningful result. Specifying nil always returns nil.


A single control event constant representing the event for which you want the list of action methods. For a list of possible constants, see UIControlEvents

Return Value

An array NSString objects containing the selector names of the corresponding action methods, or nil if there are no action methods associated with the specified target object and control event.


Use this method to determine what action methods are called on the specified object in response to a particular control event. You can use the NSSelectorFromString function to convert the returned strings to valid selectors, as needed.

See Also

Accessing the Control’s Targets and Actions

- addTarget:action:forControlEvents:

Associates a target object and action method with the control.

- removeTarget:action:forControlEvents:

Stops the delivery of events to the specified target object.


Returns the events for which the control has associated actions.


Returns all target objects associated with the control.