EPPlus is a stable, fully-featured library for working with Execl files. However, it is licensed under LGPL it is a showstopper for many businesses. In such situation a relatively new ClosedXML library may be handy.
It may not provide all the features of EPPlus, but is capable to handle the core manipulations with spreadsheets.
var workbook = new XLWorkbook();
var ws = workbook.AddWorksheet("data");
ws.Cell("A1").Value = 2;
ws.Cell("A2").Value = 2;
ws.Cell("A3").SetFormulaA1("=A1+A2");
Console.WriteLine(ws.Cell("A3").Value);
workbook.SaveAs("calculations.xlsx");
blog comments powered by Disqus