objective-c 遍历表格的方法0+
44,597 views / 2011.08.25 / 9:09 下午
for (int i = 0; i < [ptableView numberOfSections]; i++) { for (int j = 0; j < [ptableView numberOfRowsInSection:i]; j++) { NSUInteger ints[2] = {i,j}; NSIndexPath *indexPath = [NSIndexPath indexPathWithIndexes:ints length:2]; UITableViewCell *cell = [ptableView cellForRowAtIndexPath:indexPath]; //Here is your code } } |
希望对你有帮助。