Hello,
I'm using a virtual gird in V5.1.
We want to achieve an Excel like scrolling effect.
When the user clicks on the increment arrow (performing a small increment) at the extremity of the dataset we want to add new rows to the dataset dynamically. This much is fine. We then want to achieve these two things:
* After adding the new rows we would like the thumb track to remain at the end of the scroll bar - there should be no open space between the thumb track and the arrow.
* We do not want to see any ugly open space after the last column - we'd like to see part of another empty column like you get in Excel.
We've been able to either keep the thumb track at the end of the scroll bar and get the ugly open space OR have the scroll bar resize to accommodate an additional, unnecessary row at the end to get the visually appealing 'full column' effect. We cannot get both working at once.
The example provided has a suitable horizontal scroll handler setup to show adding additional rows to achieve the full column effect while getting a resizing scroll bar. Just run the sample and scroll to the right.
By commenting out line 39 of GridControlScrollingTest where the horizontal scroll handler is set you can get the ugly space at the end that is the default grid behavior.
It would be nice to have a static member variable that would take a given number of rows/columns from the QueryColCount result and use that value as the last column to display - this would give a screen full of columns.
It would be even nicer to have a setting provided that would always fill the screen with empty columns whenever there were not enough real columns available to fill the screen.
Perhaps there are other, better ideas to get around this? An already existing solution I have not found?
Thank You,
Ben
GridControlScrollingTest.zip