Quantcast
Channel: EPPlus Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 2262

Created Unassigned: File Format Corruption [14927]

$
0
0
I am hitting an issue where the Worksheet formatting is being corrupted after I open, make a small change, then re-save a sheet.

Here is the example code:

```
public static void TestExcelOutput()
{
var path =
@"C:\Users\bill\Documents\Visual Studio 2010\Projects\EPPlusTest\EPPlusTest\Input.xlsx";
var inputFileInfo = new FileInfo(path);

var outputPath = Path.Combine(Path.GetDirectoryName(path), string.Format("{0}{1}.{2}", Path.GetFileNameWithoutExtension(path),
"-processed", Path.GetExtension(path)));
var outputFileInfo = new FileInfo(outputPath);

using (var package = new ExcelPackage(inputFileInfo))
{
foreach (var worksheet in package.Workbook.Worksheets)
{
worksheet.SetValue(1, 1, "foo");
}
package.SaveAs(outputFileInfo);
}

}
```
For me, after re-saving, some of the cell borders in the Analyst tab are lost.

Viewing all articles
Browse latest Browse all 2262

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>