Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1965
Export several grid to a single Excel
posted

Hi,

could any one help to export several grids' data to a single export file?

I would appreciate, if any one oculd provide sample.

 

Thanks in advance,

Parthiban Sekar

Parents
No Data
Reply
  • 37874
    posted

    Hi Parthiban,

    You should just pass an array of WebDataGrids to the Export method:

    protected void Button1_Click(object sender, EventArgs e)

    {

        WebDataGrid[] gridsToExport = new WebDataGrid[2];

        gridsToExport[0] = WebDataGrid1;

        gridsToExport[1] = WebDataGrid2;

        WebExcelExporter1.Export(gridsToExport);

    }

    Let me know if you have any further questions.

Children