If it is added directly to the cell as a preview, you can use -superview to get its parent view. In addition, you need to specify pointers, because objects are never taken by value, and is only specified in Objective-C.
-(IBAction)done:(id)sender { [(CustmCell*)[(UIButton*)sender superview]someAction]; }
source share