is there a way to add cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton;
to each row in a table without using delegate tableView functions?(the reason for this is a bit complicated..)
im thinking on stuff like
for(UITableViewCell *cell in TheTable){
cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton;
}
but this wont work..
any ideas?
ty in advance!
You will never have access to all the cells from the
UITableViewobject. You can access the visible cells like @Jhaliya mentioned. Of course your best approach here is to have aBOOLinstance variable to keep track of whether cells have the detail disclosure button and flip them.BOOL isDetailDisclosureAccessoryVisible;
In
tableView:cellForRowAtIndexPath:,When you want to make them available,