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
25
problem with export to excel
posted

I am trying to modify the contents of a grid and then export it to excel. I use

if(cgrdResults.Columns.Exists("DATE"))

{

cgrdResults.ColFromKey(
"DATE").Format=this.Formatting.ShortDate();

}

to modify the format of DATE from  

2008-11-27 12:02 μμ

to

27/11/2008

and

cgrdResults.ForExport=true;

gridExporterToExcel.Export(cgrdResults);

to export the results, but all I get is DATE is the first format even though while debuging the procedure does not fail, there are no built or run time errors and the line of code that modifies the format is indeed executed!!! Any ideas or suggestions on how to go on about it?