I want to use EPPlus for data entry and calculation.
Here is my code:
ExcelWorksheet sheet = ep.Workbook.Worksheets["input"];
sheet.Cells[1, 1].Value = 10;
ep.Workbook.Calculate();
string test = sheet.Cells[1, 5].Text;
ep.Save();
String test: "#NAME?"
It seems that EPPlus did not load the user definition function.
When I open the saved file, the calculation will be performed automatically.
What should I do to get a custom function to work?
(I will use this function later in ASP.NET to call user definition functions in an existing excel file. I tried Interop, it can achieve what I want, but much slower.)
Thank!
source
share