mercredi 27 août 2014

transfer from c# to excel with multiple sheets


Vote count:

0




I have a few different dictionaries with different categories of information and i need to output them all into an xls or csv file with multiple spreadhseets. Currently, I have to download each excel file for a specific date range individually and then copy and paste them together so they're on different sheets of the same file. Is there any way to download all of them together in one document? Currently, I use the following code to output their files



writeCsvToStream(
organize.ToDictionary(k => k.Key, v => v.Value as IacTransmittal), writer
);
ms.Seek(0, SeekOrigin.Begin);
Response.Clear();
Response.AddHeader("Content-Disposition", "attachment; filename=" + fileName);
Response.AddHeader("Content-Length", ms.Length.ToString());
Response.ContentType = "application/octet-stream";
ms.CopyTo(Response.OutputStream);

Response.End();


where writeCsvToStream just creates the text for the individual file



asked 1 min ago







transfer from c# to excel with multiple sheets

Aucun commentaire:

Enregistrer un commentaire