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. Image for the cookie policy date
close icon

GroupingGridToExcel

I populate the dataset and the grid shows the records added into the dataset fine, however when I export to Excel using GroupingGridToExcel it displays none, for some reason it is not picking up the records in the dataset.. Do I need to do some kind of binding after adding rows to dataset. Well it displays fine, so I assume the grid gets the dataset information well. Please help.

7 Replies

AD Administrator Syncfusion Team February 6, 2007 05:14 PM UTC

Hi Gkrish,

The attached sample demonstrates the conversion of contents in a GridGroupingControl to an xls file. The Exporting of a GridGroupingControl has two options: one converts the entire contents in the grid while the other converts only the visible contents in the grid.

Here is a sample.
Excel Export.zip

Best regards,
Haneef


GK Geetha Krishnamurthy February 6, 2007 05:55 PM UTC

Yes I have the sample, my problem is. I add records into a dataset in my code on a buttonclick event and these records display on grid, however when i try to export to excel as per example, i get no records.. just like the application when it launches with no records. Before I click the button to add records.

so there is possibily some thing that has to be done if one populates the dataset on button click.


AD Administrator Syncfusion Team February 6, 2007 07:30 PM UTC

Hi Gkrish,

Thanks for the update. Is it possible for you to explain us more details or modify the sample, so it help us to solve your issue earlier. The following attached sample is working fine with excel export, please let us know if you meant different scenario.

Here is a sample.
ModifiedExcel Export.zip

Best regards,
Haneef


GK Geetha Krishnamurthy February 7, 2007 04:55 PM UTC

Could not load file or assembly 'Syncfusion.Grid.Grouping.Windows, Version=4.401.0.49,

I get the above error with the modified excel sample attached by you.

However I will try to explin the problem better. I doubt it is anything to do with Export to Excel functionality. It seems like the dataset is not binding well. It takes the binding at designtime and does not refresh.

At the code level I retrieve records from DB and add records to the dataset and these newly added records display well and correct.

However when I call GroupingGridToExcel on this it launches excel with 1 items none record, data as seen at design time...


GK Geetha Krishnamurthy February 7, 2007 10:25 PM UTC

figured out, the designer of syncfusion grouping grid is buggy.. One cannot select the parent table on design, but should manually edit .designer.cs 'gridgroupingcontrol1.DataSource = ds.parentTable' and that will fix most the problems posted by me.


CF Claudio Fernandes Bezerra March 22, 2018 11:05 PM UTC

ddddd


SN Sindhu Nagarajan Syncfusion Team March 23, 2018 04:38 AM UTC

Hi Claudio, 
  
Thanks for the update.  
  
please let us know whether you need further assistance on this. 
  
Regards, 
Sindhu  


Loader.
Live Chat Icon For mobile
Up arrow icon