excel表格的B1单元格能读出数据,但写不进去
using (ExcelPackage resultExcel = new ExcelPackage(new FileInfo(@"..\..\出货报告\" + textBox1.Text + ".xlsx")))
{
ExcelWorksheet resultWS = resultExcel.Workbook.Worksheets["出货报告"];//目标工作表格
MessageBox.Show(((string)(resultWS.Cells["B1"].Value)).Replace("****", "P20"));
resultWS.Cells["B1"].Value = ((string)(resultWS.Cells["B1"].Value)).Replace("****", "P20");
resultWS.Cells["B1"].Style.Font.Name = "Arial";
resultWS.Cells["B1"].Style.Font.Bold = true;
resultWS.Cells["B1"].Style.Font.Size = 18;
resultWS.Cells["B1"].Style.HorizontalAlignment = ExcelHorizontalAlignment.Center;
resultWS.Cells["B1"].Style.VerticalAlignment = ExcelVerticalAlignment.Center;
resultWS.Cells["B1"].Style.WrapText = true;
resultWS.Column(11).Width = 50;
resultExcel.Save();
}