Hello together,
my company has many tables with much more rows. So i had programmed a background loader, that loads these rows into da .net dataset.
Now my question is:
Is it possible to show the rows of a table while the table get filled? This means, that the ultra grid has to show the rows which are currently in this table.
Currently it is, that all rows will be displayed, after the load has finished.
If it is possible it would be very great.
Best regards,
The LittleProgrammer
This is possible, but it's not easy. You cannot bind the grid to a data source that is being populated on another thread, because the data source will send notifications to the grid that are not on the same thread and this is almost certain to cause problems. If you are going to use a separate thread, then you have to make sure that the data is properly marshalled to the UI Thread. It's really too complex a subject to discuss in a forum post, but I don't think what you are trying to do is very practical. After all, if you load the data onto the UI thread in parts, then it would defeat the purpose of using the background thread... if you are going to do that, you might as well just load the data on the UI Thread.
The WinGrid does have Load-On-Demand functionality, but you would probably need to use the UltraDataSource as an intermediary between the grid and the data source. Again, I'm not sure threading would help here.
Hello,
first thanks for your informations. So i would like to try to use the UltraDataSource. But i don't know how i could bind an dataset to the UltraDataSource. Could you give me an example or an link?
This would be very nice from you.
Hi Tobias,
There's a sample installed with NetAdvantage that displays 1 million rows in the grid. The data in this example is just generated randomly, but the principle is the same - you just get the data from your data source.
I beleive the same sample exists both under the UltraDataSource samples and in the WinGrid SamplesExplorer sample.
Hi,
From sample that is installed, shows only output, can you tell me the code where it is written about the binding of UltraDataSource to UltraGrid, Try to reply asap.
Thanks in advance.
r_senapati said:From sample that is installed, shows only output, can you tell me the code where it is written about the binding of UltraDataSource to UltraGrid, Try to reply asap.
I'm not sure what you mean. The samples and all of the source code for them is included in the NetAdvantage SDK, which you can download separately from the Infragistics web site.