I am using GetCellValue in the UltraGrid's InitializeRow to determine if I should set an appearance to the cell. Basically, if the cell value = x we set the backcolor to RED. This works just fine except it caused the bindingsource's offend event to continually fire until all records have been retrieved from the database.
We are batching 50 records at a time since the database table may have up to a million records. Our batching logic works just fine until we add the call to GetCellValue. It is like the GetCellValue is causing the UltraGrid to want ALL the data. Is this expected behaviour?
Hi Roger,
I can't see why GetCellValue would have any effect on the loading of grid rows, other than the row whose data you are loading.
Having said that, the grid loads all of the root-level rows by default, anyway, unless you change the LoadStyle.
If you are loading data from the grid on-demand, you might be better off using the UltraDataSource as an intermediary between the grid and the actual data as demonstrated in the Virtual Mode sample.
Mike,
I am not sure why the GetCellValue would effect the loading of the grid but I do have a workaround. I basically disable my batching in the beginning of InitializeRow and then enable batching at the end. This seems to solve the issue.
Thanks Mike.