Expand Grid Error

Hi,

I get the following error with SfTreeGrid:
When I first click any cell of the TreeGrid there is no problem. But when I first click to expand a node I get the error I documented in the uploaded file.
The same problem occurs when all nodes are expanded and I click one node to collapse the expansion first. I load an IEnumerable by EntityFramework from a mysql database. I tried to reproduce the error by filling an IEnumerable manually in a new project but without access.

Do you have any idea what is wrong or how to build a workaround?

Regards,
Jörg


Attachment: SfTreeGrid_Error_2021,329_402057ac.zip

7 Replies

MA Mohanram Anbukkarasu Syncfusion Team March 30, 2021 12:35 PM UTC

Hi Jorg, 

Thanks for contacting Syncfusion support.  

We have checked the provided document. The provided detail are not sufficient to trace out the cause for the reported issue. Kindly share the xaml and CS code snippets you have used in your application related to the SfTreeGrid and any other SfTreeGrid related customizations in your application. It will be helpful for us to find the exact cause for the issue and to provide a prompt solution at earlier.  

Regards, 
Mohanram A. 



Jörg April 12, 2021 09:28 AM UTC

Hi Mohanram,

sorry for my late reply.

Now I've found the reason for this error. I use a SfMultiColumnDropDownControl for choosing projects (McdProject) and a SelectionChanged - Event for getting the ProjectId. Then I fill the SfTreeGrid with plan data of this project.

When I expand the SfTreeGrid the McdProject_SelectionChange event raises and I don't know why.

In my earlier code the SfTreeGrid ItemsSource has been changed (with the same data) for a second time while expanding the TreeGrid.

Now I ask for changes of the ProjectId in SelectionChanged - Event and now it works. But as I wrote I don't know why a SelectionChanged Event of a SfMultiColumnDropDownControl raises when I expand a SfTreeGrid.

Regards,
Jörg


MA Mohanram Anbukkarasu Syncfusion Team April 13, 2021 12:52 PM UTC

Hi Jorg, 

Thanks for the update.  

We are able to understand the problem you are facing. But the provided details are not sufficient to reproduce the issue in our end. We suspect that expanding the TreeGrid may affect the Selection in SfMultiColumnDropDownControl, if there is any binding created for the selection related properties of SfMultiColumnDropDownControl like SelectedItem, SelectedIndex. If possible kindly the share the code snippets related to SfTreeGrid and SfMultiColumnDropDownControl. It will be more helpful for us to find the cause for the problem and to provide a prompt solution.  

Regards, 
Mohanram A. 



Jörg April 14, 2021 07:43 AM UTC

Hi Mohanram,

in the appendix you will find a test program. Please start the program, choose Project 1001 in the SfMultiColumnDropDownControl, then try to expand the SfTreeGrid, the error occurs.

Regards,
Jörg



Attachment: CAMACproject_a6d81906.zip


MA Mohanram Anbukkarasu Syncfusion Team April 15, 2021 07:34 AM UTC

Hi Jörg, 

Thanks for the update.  

We have checked the provided sample by restoring the NuGet you have already installed in it. But unfortunately, the SfTreeGrid expanded properly without any exception. Please find the video from the below given link in which you can see that the SfTreeGrid is expanded without any exception.  


We are little unclear with the reported problem as we are unable to reproduce it in the same sample with same NuGet version in our end. Kindly share more details about the exception and the stack trace details of the exception. It will be helpful for us to check the possibilities for getting this exception and to provide a prompt solution.  

Regards, 
Mohanram A. 



Jörg April 15, 2021 11:32 AM UTC

Hi Mohanram,

I don't know why you can't reproduce this error. But please try the following.

Set a break point at line 107 of Master.xaml.cs:

var selectedValue = (sender as SfMultiColumnDropDownControl).SelectedValue;

Start the program, choose project 1001 and expand one of the parent nodes. My problem was, that clicking with mouse on the expand icon raised the McdProject_SelectionChanged event. 
Do you have the same behaviour? In my opinion that cannot be correct, that clicking on a Treegrid to expand it raises a  SfMultiColumnDropDownControl SelectionChanged event.

If you don't have the same behaviour please close this thread, because I have solved my problem.

Regards,
Jörg


MA Mohanram Anbukkarasu Syncfusion Team April 16, 2021 01:45 PM UTC

Hi Jörg, 

Thanks for the update.  

The SfMultiColumnDropDownControl.SelectionChanged event doesn’t call when expanding TreeGrid in other samples. However we are glad to know that you have resolved the reported problem in your end. Please let us know if you require any other assistance from us.  

Regards, 
Mohanram A. 


Loader.
Up arrow icon