Accessing another buttons method

Discussion in 'iOS Programming' started by beardedpig, Mar 24, 2009.

  1. beardedpig macrumors member

    Joined:
    Dec 17, 2008
    #1
    Is it possible to have a button that has a method that processes its tap event to another button?

    So button A is tapped and all it does is pass this tap to button B so it is button B's code that runs.
     
  2. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #2
    Why not just connect button A's action to the same method that button B is calling?
     
  3. beardedpig thread starter macrumors member

    Joined:
    Dec 17, 2008
    #3
    got it :)

    Code:
    [targetButton sendActionsForControlEvents:UIControlEventTouchUpInside];
    
     

Share This Page