我正在尝试迭代并在我的文本视图集合上显示我的数组。
@property (strong, nonatomic) IBOutletCollection(UITextView) NSArray *myTextViewCollection;
但是在 UI 上,只有我的数组中的最后一个元素可用。
我迭代:
for (UITextView *textView in myTextViewCollection) {
for (int i = 0; i < feeds.count; i++) {
textView.text = [[feeds objectAtIndex:i] objectForKey:@"title"];
textView.editable = false;
}
}
feeds
是一个包含 NSMutableDictionnary 对象列表的 NSMutableArray。
一个主意 ?