Iphone 关于UILabel事件的问题

Iphone 关于UILabel事件的问题,iphone,objective-c,uilabel,Iphone,Objective C,Uilabel,我在UITableViewCell中有一些UILabel。我的目的是在触摸特定的UILabel时调用函数。请给我一个思路。 谢谢。UILabel是UIResponder的一个子类。您可以覆盖以下方法来处理触摸 – touchesBegan:withEvent: – touchesMoved:withEvent: – touchesEnded:withEvent: – touchesCancelled:withEvent: UILabel是UIResponder的一个子类。您可以覆盖以下方法来处

我在UITableViewCell中有一些UILabel。我的目的是在触摸特定的UILabel时调用函数。请给我一个思路。
谢谢。

UILabel是UIResponder的一个子类。您可以覆盖以下方法来处理触摸

– touchesBegan:withEvent:
– touchesMoved:withEvent:
– touchesEnded:withEvent:
– touchesCancelled:withEvent:

UILabel是UIResponder的一个子类。您可以覆盖以下方法来处理触摸

– touchesBegan:withEvent:
– touchesMoved:withEvent:
– touchesEnded:withEvent:
– touchesCancelled:withEvent:

是的,你是对的,但是我发现userInteractionEnabled属性必须分配给Yes,然后它才真正起作用。是的,你是对的,但是我发现userInteractionEnabled属性必须分配给Yes,然后它才真正起作用。