开发者

Getting NSTextField by tag number?

开发者 https://www.devze.com 2022-12-16 03:41 出处:网络
I\'ve got a bunch of NSTextFields on a window (tagged 1-8) and I\'m wondering if it\'s possible to access each individual text field programatically by its tag number so I can then get/set its value?

I've got a bunch of NSTextFields on a window (tagged 1-8) and I'm wondering if it's possible to access each individual text field programatically by its tag number so I can then get/set its value?

I'm a newbie and while I know how to access these 开发者_开发问答fields by name, doing it by tag number will make things an awful lot simpler for what I'm trying to achieve in this particular instance.

Thanks a lot :-)


the_fourth_textview = [the_superview_containing_all_textfields viewWithTag:4];
0

精彩评论

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