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

Export to excel including detail template

Thread ID:

Created:

Updated:

Platform:

Replies:

143591 Mar 28,2019 08:09 AM UTC Mar 29,2019 09:06 AM UTC ASP.NET MVC - EJ 2 1
loading
Tags: Grid
afiqdoherty
Asked On March 28, 2019 08:09 AM UTC

Hi,

I have read the solution on exporting detail template to excel on grid. but, still I don't understand and not sure if it is doable in EJ2. Hope you can help me with sample on how to export my grid to excel including grid that has detail template. FYI, I'm using method of exporting multiple grid data in the same excel. the file is downloaded well but without detail template. appreciate if you can help me :)  below is the code to download multiple grid in same sheet.


<script>
    function toolbarClick(args) {
            var firstGrid = document.getElementById("List_Declaration_Info").ej2_instances[0];
            var secondGrid = document.getElementById("List_Invoice_Info").ej2_instances[0];
            var thirdGrid = document.getElementById("List_Vehicles_Info").ej2_instances[0];
            var fourthGrid = document.getElementById("List_Containers_Info").ej2_instances[0];
            var appendExcelExportProperties = {
                multipleExport: { type: 'AppendToSheet', blankRows: 2 }
            };

            var GridExport = firstGrid.excelExport(appendExcelExportProperties, true);

            GridExport.then((fData) => {
                secondGrid.excelExport(appendExcelExportProperties, true, fData).then((fkData) => {
                    thirdGrid.excelExport(appendExcelExportProperties, true, fkData).then((fData) => {
                        fourthGrid.excelExport(appendExcelExportProperties, false, fData);
                    })
                });
                
                
            });
    }
</script>


regards,


afiq

Pavithra Subramaniyam [Syncfusion]
Replied On March 29, 2019 09:06 AM UTC

Hi Afiq, 
 
Greetings from Syncfusion. 
 
Query #1: Export to excel including detail template 
 
We have analyzed your query but we do not have support to export detail template of the grid component as the template may almost contain anything(text, image, etc.). So if you have bind a grid component in the detail, then we suggest to use the hierarchy grid export, please refer to the below sample for your reference, 
 
 
 
Please get back to us for further assistance. 
 
Regards, 
Pavithra S. 
 


CONFIRMATION

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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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

;