Possible bug in CSV creation


I have the following line of code in my application.

excel.Save( errorCategory.ToString() + “.xls”, SaveType.OpenInExcel, FileFormatType.Excel97, response );

I made a change to it recently to try sending a CSV to the user instead of a native Excel file. The resulting line of code was:

excel.Save( errorCategory.ToString() + “.csv”, SaveType.OpenInExcel, FileFormatType.CSV, response );

The problem that resulted can be seen in the attached zip. As you can see in Class.xls, columns B and C have column headers in row 1 but the cells below row 1 for those two columns are empty.

In Class.csv, the first non-header row is:

Warning,CRF Class Subject Name longer than 20 characters…

Notice there is only one comma between Warning (column A) and “CRF Class…” (column D). It should be:

Warning,CRF Class Subject Name longer than 20 characters


Thanks for your report. I will fix it in next version.