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

Kendo grid row unseleced during ajax refresh

1 Answer 33 Views
Grid
This is a migrated thread and some comments may be shown as answers.
ianc
Top achievements
Rank 1
ianc asked on 24 Feb 2014, 11:25 AM
Hi I am using Kendo Grid with autorefresh each 5 seconds, The problem is that after refresh when table is rebuild, selection of the row is lost and restoration is visible, what I mean is I can see blinking of selection during data update.In telerik extension there was an event OnRowDataBinding wich was triggerd after each row data binding and we could restore selection very nice, but here is only event DataBound and Kendo says to loop throu all items but because of that selection restoration is very visible and it looks terrible. What I could do ?function onParkedOrderGridDataBound(e) {

var data = this.dataSource.view();
var dataItem = data[0];
var tr = $parkedOrderGrid.find("[data-uid='" + dataItem.uid + "']");
AcceleratorDealingUiKendoGridCheckBoxSelector.MarkRowAsSelected(tr, true);
var $row = $(tr);
$row.addClass("k-state-selected");
}

1 Answer, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 25 Feb 2014, 11:25 AM
Hello Lukasz,

I can't recreate a scenario, which makes setting selected state class flickerish and visible to the user. Probably you have a too heavy page and the Grid has too many rows?

A possible option is to disable the built-in Grid Ajax overlay mechanism and use your custom, which removes the overlay after the selected states have been reapplied. The custom overlay will be more opaque, so that the flickering is less visible.

http://jsfiddle.net/dimodi/dYcHg/

Regards,
Dimo
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Grid
Asked by
ianc
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or