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

Grid cell color changing for a big dataset

3 Answers 79 Views
Grid
This is a migrated thread and some comments may be shown as answers.
UFIS
Top achievements
Rank 1
UFIS asked on 09 May 2014, 09:20 AM
Dear Support Team,

I have a grid which is showing a dataset which has thousands of rows data.
When the next datafeed comes in, I'd like to highlight the cell of which the value is updated or changed.
In the menudatabound event, I tried to compare the two datasets (one is the old and one is the new) and try to highlight the change using a line as below:

$("#mygrid tr[data-uid='" + row.uid + "']").find("td").eq(k).css("background", "lightgreen");

It's very slow, it's OK for up to hundreds of rows.
We don't use any paging in the front-end nor in the back-end datafeeding service.
Can there be any workaround?
Can you please advise any alternative?
Is there any faster way to access the background color of the cell and change it?

Thanks & regards
UFIS

3 Answers, 1 is accepted

Sort by
0
UFIS
Top achievements
Rank 1
answered on 09 May 2014, 09:22 AM
*Correction: In the menudatabound event  > In the dataBound event 
0
Vladimir Iliev
Telerik team
answered on 13 May 2014, 08:39 AM
Hi,

Basically there is no better way of finding the needed row other than using the model "uid" and in current case I can only suggest to try optimizing the selector for finding the cell at given index. Also you can try optimizing the loop that you are using for comparing the two data sets. For more information about how to optimize the selectors you can check the following thread at StackOverflow:

Regards,
Vladimir Iliev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
UFIS
Top achievements
Rank 1
answered on 15 May 2014, 04:53 AM
Thanks a lot for the information.
I'll take a look at that.
Tags
Grid
Asked by
UFIS
Top achievements
Rank 1
Answers by
UFIS
Top achievements
Rank 1
Vladimir Iliev
Telerik team
Share this question
or