We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Virtual Grid

I am looking for a technical definition of how the virtual grid works. Particularly, I am wondering how often, if ever, essential grid will query to find the current number of rows. Is this configurable, etc.

For instance, when my app starts my grid is empty. When the user clicks a certain button, a background thread fires off that populates my data-structure with somewhere around 200,000+ rows. From what I can tell, essential grid fires QueryRowCount on start-up but will not fire that event again. So, my grid remains empty. To get around this, I have been manually forcing a refresh which causes the essential grid to once again fire QueryRowCount. But the grid will only show the rows that are currently in the data-structure when it fires QueryRowCount. It isn't continually aware that my data-structure is growing. Is there anyway to overcome this? What do other people do in this case? Technical documentation of the virtual grid would be helpful.

Thanks.


7 Replies

AD Administrator Syncfusion Team October 1, 2008 07:25 PM UTC

You can get the GridControl to raise QueryRowCount/QueryColCount by explicitly calling

grid.ResetVolatileData();


If you make a grid.Refresh() call, this will also trigger a grid.ResetVolatileData() call.



SM Sam McIngvale October 1, 2008 09:33 PM UTC

Looks like ResetVolatileData() forces grid cells that are visible at the moment to reload all their data from data source. Is there anyway to not do this and just force a reload of the row/column count. ie. Can I manually fire the QueryRowCount event or force this to fire in someway that won't cause my cells to re-paint? That's really what I want to do.

>You can get the GridControl to raise QueryRowCount/QueryColCount by explicitly calling

grid.ResetVolatileData();


If you make a grid.Refresh() call, this will also trigger a grid.ResetVolatileData() call.





AD Administrator Syncfusion Team October 2, 2008 07:37 PM UTC

Normally, just calling ResetVolatileData does not trigger any QueryCellInfo calls. Here is a sample that puts a different value and color into a cell everytime QueryCellInfo is called. There is also a button event that adds 10 rows to the grid and then calls ResetVolatileData so the grid knows about the new rows. During the button click, there is not QueryCellInfo activity.

http://www.syncfusion.com/support/user/uploads/GC_Virtual_42a7eb8b.zip






WG Wim Gilbert October 16, 2008 07:46 AM UTC

Does this also work for a grid grouping control?

>Normally, just calling ResetVolatileData does not trigger any QueryCellInfo calls. Here is a sample that puts a different value and color into a cell everytime QueryCellInfo is called. There is also a button event that adds 10 rows to the grid and then calls ResetVolatileData so the grid knows about the new rows. During the button click, there is not QueryCellInfo activity.

http://www.syncfusion.com/support/user/uploads/GC_Virtual_42a7eb8b.zip








NA Nisha Arockiya A Syncfusion Team October 17, 2008 06:45 AM UTC

Hi Wim,

You can call QueryRowCount/QueryColCount explicitly in GridGroupingControl by using the code snippet as below:


this.gridGroupingControl1.TableModel.ResetVolatileData();


Please let me know if this helps.

Regards,
Nisha



VS Vladimir Shcherbina May 11, 2009 03:53 PM UTC

Hi,


Could you provide a full example of the virtual grid, which is based on GridGroupingControl?
Thanks,
Vladimir


JJ Jisha Joy Syncfusion Team May 12, 2009 06:37 AM UTC

Hi Vladimir,


Please see Engine Optimization Demo sample in our sample browser, that demonstrates virtual-mode and without-counter-mode optimization in GridGroupingControl.
..\\My Documents\syncfusion\essentialstudio\7.2.0.20\Windows\Grid.Grouping.Windows\Samples\2.0\Performance\Engine Optimization Demo\cs

Please let me know if this helps.

Regards,
Jisha

Loader.
Live Chat Icon For mobile
Up arrow icon