日期:2014-05-20 浏览次数:20831 次
string str = worksheet.Cells["E22"].Formula;
str = str.Replace("AAA()", "1");
str = str.Replace("BBB()", "2");
str = str.Replace("ccc()", "3");
//str.Substring(
worksheet.Cells["E22"].Formula = str;
//ep.Workbook.Properties.SetCustomPropertyValue
ep.Save();
//ep.SaveAs(new FileInfo(fileName));
//worksheet.Cells["E22"].Formula = "1";
//worksheet.Cells["E22"].Formula.Insert(1, str);
Console.WriteLine(worksheet.Cells["E22"].Formula);