- Home
- Forum
- ASP.NET Web Forms
- Export fail in dynamic grid
Export fail in dynamic grid
I've a project that the user can generate, in real time, a determinate number of grids.
I've created an user control with the grid, and I put this user controls on a panel.
it works fine, but when I want to excel export, it doesn't work. The user controls disappear.
I attach an example project with the problem. When the botton is clicked I generate the user controls.
Attachment: GridExport_92459c27.zip
Thanks for contacting Syncfusion support.
For every Grid post action, we have to re-initialize the user control and in every Grid action event, the page load event will trigger. While exporting to Excel, we suggest you to re-initialize the user control. In the page load method, we checked the condition with postBack, and re- initialized the user control.
Please find the following code example and sample,
| protected void Page_Load(object sender, EventArgs e) { if (IsPostBack) { lv.Controls.Clear();
var di = (DatosInforme)LoadControl("~/UserControls/DatosInforme.ascx");
di.ID = "Direct";
var datos = LoadData();
di.SetDataSource(datos);
lv.Controls.Add(di); } |
Sample Link: https://www.syncfusion.com/downloads/support/forum/120494/ze/GridExport541119425
Regards,
Prasanna Kumar N.S.V
And if I filter, grouping... this configuration is saved when I export! =)
After filtering or grouping the grid, the filtered column or grouped column details will be stored in the filteredColumns property of filtersettings or groupedColumns property of groupsettings. While exporting, it exports only the filtered data or grouped data.
Are you facing any issue while exporting after filtering or grouping operation?
Regards,
Prasanna Kumar N.S.V
I wanted to say that when I export filters, agrupoaciones remain ... so I'm glad =)
Thanks again
While running the sample, grouping is not shown in the Grid. Please find the below screenshot,
But while exporting to Excel, grouping remain in the Excel sheet. Please find the below screen shot,
Please confirm if this is the issue that you are facing while using filtering in the Grid. If we misunderstood your query, please send a screenshot of an issue, which will be helpful to provide a better solution.
Regards,
Prasanna Kumar N.S.V
Thanks alot
We are happy that your doubts are cleared and all working fine at your end
Please get back to us if you have further queries.
Regards,
Prasanna Kumar N.S.V
I'm testing the export options, and I've a problem:
- if I grouping, the excel exportation is grouped (perfect)
- if I filter, the excel exportation show all rows, not only the filtered.
I've modified our example for test
Attachment: GridExport_6aae29b0.zip
We able to reproduce the mentioned issue. This issue has been fixed and it has been included in the Volume 2, Service Pack 2 release (13.2.0.39). So we suggest you to upgrade to the latest Essential studio version.
We have attached the sample in the following link
Sample Link: https://www.syncfusion.com/downloads/support/forum/120494/ze/GridExport-1753117254
But while filtering the records using equal operator, we unable to export the filtered records. So, we have already created defect report for that issue and a support incident has been created under your account to track the status of this requirement. Please log on to our support website to check for further updates.
https://www.syncfusion.com/account/login?ReturnUrl=/support/directtrac/incidents
Regards,
Prasanna Kumar N.S.V
Thanks for the update.
Please get back to if you need any further assistance. We will be happy to assist you.
Regards,
Balaji Marimuthu
- 11 Replies
- 3 Participants
-
MA Manolo
- Sep 21, 2015 10:26 AM UTC
- Oct 2, 2015 12:46 PM UTC