We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

System.StackOverflowException with GridGroupingControl

Thread ID:





16292 Jul 12,2004 12:51 AM UTC Jul 12,2004 06:37 AM UTC WinForms 2
Tags: GridControl
Administrator [Syncfusion]
Asked On July 12, 2004 12:51 AM UTC

Hi, I am using the Syncfusion.Windows.Forms.Grid.Grouping.GridGroupingControl. I have followed a process similar to the tutorial "Project1- Binding a GridGroupingControl to a MDB file" except in my case I am using SQL server and stored procedures. I have used the "Generate Dataset" feature from right clicking on the data adapter to add a dataset to my design surface. The problem comes when I attempt to set the DataSource property of the GridGroupingControl to the dataset. I can specify the correct dataset in Properties but as soon as I move focus away from the DataSource property, there is a brief pause before a System.StackOverflowException occurs. If I take up the invite to attach a debugger, the actual crash seems to be occuring within System.Drawing.Graphics.DrawImage [New Information] While I was writing this, I just tested something new and discovered that there was a problem with my querystring associated with the data adapter. I think what is happening is that the designer is attempting to run the query in order to get the metadata (column names) etc. for the Grid Headings. As the bad querystring is causing the data adapter to return an error instead of the metadata the whole of VS.NET crashes potentially causing loss of work. I think the Designer code of the GridGroupingControl needs looking at to cope with an error response from the data adapter more gracefully. Now that I have corrected the query string, the grid design surface is painting correctly but I thought you may want to know about this issue as I lost an hours work from the crash and others may do to.

Administrator [Syncfusion]
Replied On July 12, 2004 05:22 AM UTC

I tried to reproduce this problem in our tutorial by entering an bad Command text for teh query. Just making a column name invalid did not lock things up for me. I got an invalid parameter messagebox, and was able to correct the problem at that point. What was the exact nature of the problem in your query string so we can try to reproduce the problem to see if there is something we can do to avoid the lock up.

Administrator [Syncfusion]
Replied On July 12, 2004 06:37 AM UTC

When I had the problem I had configured the System.Data.SqlClient.SqlConnection with a ConnectionString taken from the configuration file (Click on DynamicProperties-ConnectionString-''Map property to key in configuration file''). I had set it to AppDatabaseDSN which is specified in the app.config as: With this connection string, I generated the dataset and then assigned the dataset to the grid. After moving off the grid dataset property field VS.NET crashed. After restarting and rebuilding the form to the same point as before, I tried the same thing a couple of times over. Crash each time. I then tried an alternative way of setting the connection string by clicking on the drop down for the ConnectionString property of SqlConnection - this listed a connection that I had specified in the Data Connection pane (Server Explorer). The connection string was fuller but otherwise similar - "workstation id=MyWorkstation;packet size=4096;user id=sa;data source=localhost;persist security info=True;initial catalog=AppDatabase;password=password" With this connection string, VS.NET did not crash when I assigned the associated dataset to the grid. Instead it painted the grid in design mode showing the column headings that it had extracted from the query. As a test I went back to the old way of specifying the connection string, and the crash occurred again. I don''t know why the original connection string (or way of specifying it) should not work, but I guess funny things just happen sometimes...:)


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon