开发者

How do you assign an action to multiple UITextFields using IB in xcode 4?

Is there a way to select all UITextFields and assign them to开发者_高级运维 one Received Action?


Based on your clarification, you can define an action in your controller and control-drag a connection from each field to the controller, connecting it to the same action. Since the sender (the field that fired the action) is included in the action, you can make your different choices based on the sender itself.

Read up on the Target / Action mechanism here.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜