-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Dear All,
Grid using the Checkbox and paging:
a parent Checkbox in the header, which is used to select all child checkbox,
when the status of the parent Checkbox isChecked, how to select all child a Checkbox (including all pages)?
PS. ZK Version: 5.0.9
The code now only select the first page of a Checkbox, not other pages.
JAVA CODE:
Rows rows = grid.getRows();
for (int i =0; i< rows.getChildren().size();i++)
{
Row row = (Row) rows.getChildren().get(i);
if(row.getFirstChild() instanceof Checkbox)
{
Checkbox cb = (Checkbox) row.getFirstChild();
cb.setChecked(target.isChecked());
}
}
ZUL FILE:
<grid id="grid" mold="paging" pageSize="10" vflex="true" style="overflow:auto" pagingPosition="both" >
Regards,
Lam
Asked: 2012-05-15 15:13:22 +0800
Seen: 209 times
Last updated: Jul 05 '12