【问题标题】:Get UIButton Text from sender从发件人处获取 UIButton 文本
【发布时间】:2011-03-11 07:55:12
【问题描述】:

如何获取我的 UIButton 中的文本

-(IBAction)clicked:(id)sender

方法?

谢谢

【问题讨论】:

    标签: iphone uibutton sender


    【解决方案1】:

    这个呢:

    - (IBAction)clicked:(id)sender {
      UIButton *button = (UIButton *)sender; 
      NSString *buttonTitle = button.currentTitle;
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-04-15
      • 2013-07-16
      • 1970-01-01
      相关资源
      最近更新 更多