Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by sandip on Jan 30, 2009 05:47
open dhtmlx forum
want auto scroll off

hi,

I am using dhtmlXGrid. while rendering grid, horizontal scroll bar appears. But the problem is if I double click on the last/ second last cell. the cell horizontal scroll happens and the position of the cell appears at the beginning of the grid. I don't want this behavior.

How I accomplish this task...

thank u.
sandip
Answer posted by Support on Feb 02, 2009 03:19
By default grid uses auto-scroll on selection ( adjust vertical and horizontal scroll so selected cell come in focus ) 
You can disable hor. auto-scroll by adding next code to the grid's init

grid.moveToVisibleA=grid.moveToVisible;
grid.moveToVisible=function(cell){ return  grid.moveToVisibleA(cell,true); }
Answer posted by Gaurav Arora on Feb 19, 2009 16:00
Hi,

I had a subgrid with large no of rows. As soon as i selected the parent row, it used to moveToVisible which I was finding weired for my case. The above technique was useful to me. I disabled the autoscroll feature as ..

grid.moveToVisible = function(cell){return true;};

Thanks for the above suggestion.
Gaurav