Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Jeff on Apr 01, 2009 00:40
open dhtmlx forum
SmartRender can't scroll to rowId in Pro version

Seems the lastest Pro Eval version I just got didn't fix the scroll problem in smartRender. This is the thread discussed this before. (http://www.dhtmlx.com/docs/products/kb/index.shtml?cat=5&page=16&q=3630&ssr=yes&s=getchangedrows)

I would like to use getStateOfView() to get the current row, then refresh the data from server and scroll to the prev pos.

Also, how to handle the sorting when refreshing in this case to maintain the scroll position in smartRender mode?

Thanks

Jeff
Answer posted by dhxSupport on Apr 01, 2009 05:55

In case of dynamic smart rendering mode seletRow or showRow methods will not work with rows which wasn't rendered yet.

If you don't use paginal output you can get position of a scroll bar with following code:

grid.objBox.scrollTop=grid._srdh*index+"px";

Answer posted on Apr 01, 2009 21:47

Thanks.

By setting the scrollTop it will fixed the problem however dont need to add "px". Otherwise wont work.

It seems that if I change to use XML as data source but not json, the selectRow/showRow works in smart rendering even the render wasn't completed on the whole grid for huge dataset. Can you explain if there is a difference between xml and json ?

Also possible to maintain the col order in this case?

 

 

Answer posted on Apr 25, 2009 13:28
I can't seem to get either of these two work (using smart rendering, not dynamic).

scrollTop doesn't make it scroll, and showRow doesn't do anything either.  I am calling these after grid.init();