Hi,
We have a grid containing 130+ columns and 56K+ rows. We have implemented the LoadOnDemand as the LoadStyle and we are listening to the InitializeRow event in order to set the color scheme of the some of the cells within the row. We have changed our code to follow the recommendations within the WinGrid Performance Guide article.
If the user scrolls all the way down to the bottom of the grid, we get the following exception:
Thread exception: System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown. at System.Collections.Hashtable.rehash(Int32 newsize) at System.Collections.Hashtable.expand() at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add) at System.Collections.Hashtable.set_Item(Object key, Object value) at Infragistics.Win.UltraWinGrid.UltraGridLayout.AddMulticastObjectHelper(Hashtable table, Object obj) at Infragistics.Win.UltraWinGrid.UltraGridLayout.SetMulticastAppearance(AppearanceBase appearance, Object obj) at Infragistics.Win.UltraWinGrid.UltraGridCell.set_Appearance(Appearance value) at NsbSystem.Windows.Forms.Grids.GridCell.set_ColorScheme(ColorScheme value)
Is there something we can do to avoid this exception?We are currently using version 12.1.20121.1001 of Infragistics.
Hi Annie,
With a large number of cells, it's possible that the process is simply unable to allocate memory to set the new appearance. Even if you are reusing appearances as recommended in the guide, some memory may need to be allocated for the cells. Is it possible to send over your code so we can investigate? A sample would be best, but we will look at any code you can send.
If you would prefer not to upload the code to the forum (or if you sample has a large filesize), please let me know and I will open a private case for you.