Pass different parameters to an IBAction

前端 未结 7 1426
面向向阳花
面向向阳花 2020-12-08 22:39

My iPhone app has many buttons and I want all the buttons to call the same method, but with different parameters.

For example I want tapping one button to call the m

相关标签:
7条回答
  • 2020-12-08 23:38

    (id)Sender is shows that whatever u pass on UIButton click event is directly pass to this method and no matter that what type it is , it take automatically like if you pass button tag then it take button tag as sender.tag etc

    0 讨论(0)
提交回复
热议问题