Hello :
I would like to save WebGrid Excel Exported File in a specific address by code and would not allow the download dialogue to appear because I will attach the exported file as a mail attachment.
My problem are as belows:
1.How to save WebGrid Excel Exported File in a specific address?
2. How to save WebGrid Excel Exported File without download dialogue to appear ?
Any sugestion is welcome.
Sincerely,
Daniel Lee
Hello Daniel,
The ExportMode property of the UltraWebGridExcelExporter can be set to Custom and then in the Export method you can pass the location of the file as a parameter. The following block of code should help:
this.UltraWebGridExcelExporter1.ExportMode = Infragistics.WebUI.UltraWebGrid.ExcelExport.ExportMode.Custom;
this.UltraWebGridExcelExporter1.Export(this.UltraWebGrid1, "C:\\testexcel.xls");
Here is the link to all the list of overloaded Export methods for UltraWebGridExcelExporter:
http://help.infragistics.com/Help/NetAdvantage/ASPNET/2009.2/CLR3.5/html/Infragistics35.WebUI.UltraWebGrid.ExcelExport.v9.2~Infragistics.WebUI.UltraWebGrid.ExcelExport.UltraWebGridExcelExporter~Export.html
Hope this helps.
Thanks,
Sarita
Hello Sarita:
Thanks. I got it.
Daniel