NSArray * arrayOfVisibleTVC=[BNUtilitiesQuick ListController].tableViewA.visibleCells;
NSLog(@"array : %@", arrayOfVisibleTVC);
sẽ hiển thịcách biết đường dẫn chỉ mục của UITableView.visibleCells?
"<UITableViewCell: 0x76c22a0; frame = (0 0; 320 75); autoresize = W; layer = <CALayer: 0x76bf770>>",
"<UITableViewCell: 0x76cfec0; frame = (0 75; 320 75); autoresize = W; layer = <CALayer: 0x769d260>>",
"<UITableViewCell: 0xe245f70; frame = (0 150; 320 75); autoresize = W; layer = <CALayer: 0xe245ed0>>",
"<UITableViewCell: 0xe248980; frame = (0 225; 320 75); autoresize = W; layer = <CALayer: 0xe2488c0>>",
"<UITableViewCell: 0xe24afa0; frame = (0 300; 320 75); autoresize = W; layer = <CALayer: 0xe24aee0>>"
và với điều này
UITableViewCell * lastObjectOfArray=arrayOfVisibleTVC.lastObject;
int indexpathLastObject= (lastObjectOfArray.frame.origin.y/new.frame.size.height);
Tôi biết cuối cùng của arrayOfVisibleTVC.lastObject mà tôi sử dụng để có được indexPath. nhưng tôi nghĩ rằng có một cách khác để có được indexpath của TableViewcell cho thấy .. bất kỳ ai có thể giúp tôi?
vì vậy tôi có thể nhận được indexPath của tế bào như nguyên
Bạn thử *** indexPathForCell: ** * phương pháp? – EmptyStack