NullReferenceException when editing the in the sorted column

In the attached demo, I have a form with a bound grid (version 3.0.1.0) and a GridFilterBar wired to the grid. I also have a DataSet which I set the Tables[0].DefaultView.Sort to the first column table and then set Table[0] as the grid''s DataSource. If I edit the any of the cells in the first column in such a way to cause it to resort when I leave the row, I get a NullReferenceException. Run the sample, change the cell containing "ID 1" to "xxxx" and leave the row. --> NullReferenceException. This happens down in grid code and there is no way I that I know to catch the exception myself. If I do not wire the GridFilterBar, the exception will not occur. If I double-click the second column''s header to change the sort order, and then double-click the first column''s header to change the sort order back, the NullReferenceException will not occur. Is there a preferred method to setup the sort during the form''s Load routine? I am currently using the DefaultView.Sort property on the DataTable. Should I be using a method/property on the grid instead? This behavior is not reproducable on all machines. I have a collegue who cannot reproduce this behavior. However, he is not running Windows XP Service Pack 2 (I am). We are however both running the same version of syncfusion essential suite.

ExceptionDemo.zip

1 Reply

AD Administrator Syncfusion Team March 20, 2006 03:56 PM UTC

Hi JP, The issue is working fine here (Windows XP Service pack 2). Please refer to the attached image illustrating the desired output . Please try this issue in our later versions and let us know if this helps. And kindly send call stack. Best regards, Madhan.

Loader.
Up arrow icon