This is a migrated thread and some comments may be shown as answers.

[Solved] URGENT : Unselect checkbox on client side not working

1 Answer 89 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jérôme Piquet
Top achievements
Rank 1
Jérôme Piquet asked on 17 Sep 2009, 11:59 AM
Hi,

If I execute this code in the OnCommand client-side event :

var elems = sender.get_masterTableView().get_dataItems();
for(var i=0;i<elems.length;i++)
{
  elems[i].set_selected(false);
}
           
or this code : sender.get_masterTableView().clearSelectedItems()

it seems to unselect the dataitem in memory but not uncheck the checkbox html control.

If i get the html checkbox with get_element() and I unselect him,  I also have a problem when the user want to click a chekbox previously selected on a other page : he need to click twice on an unchecked checkbox to check ...

Is there a way to simple solve this problem ?

I need to clear all checked checkbox when paging (full ajax), and keep the item checked in memory. When the user return on a page where checkbox are previously checked, I need to check them automatically.

thanks for you help !

Jérôme


1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 23 Sep 2009, 10:09 AM
Hello Jérôme,

Please refer to the following code library for more information about how to achieve the desired functionality:
Check/Uncheck all checkboxes in template column and selecting rows with checkbox

I hope this helps.

Regards,
Pavlina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Grid
Asked by
Jérôme Piquet
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Share this question
or