I've got an xlsx file with a formula that refere a cell on another sheet like this :
=Feuil2!B1
But the Cell B1 doesn't exist, so there is a bad reference : =Feuil2!#REF!
There is no problem with an invalid reference on the same sheet.
I can't open this file. The stack trace is :
Aspose.Cells.CellsException: Error in Cell: J21-Invalid formula:"='RH-IN'!#REF!*80%". à Aspose.Cells.x40937ad35b1cf5f7.x1f490eac106aee12(Cell xe6de5e5fa2d44af5, String xef81f2df12e64618, Byte x804d9de34bfbea97) à Aspose.Cells.OpenXML.x7661ca2b53df3da9.xb953ef709de3d2ab(XmlTextReader xb9763b0038341e6c, Int32 x3e0a106e44f5f6eb, Int32 x5b0d56b787e972e9) à Aspose.Cells.OpenXML.x7661ca2b53df3da9.xd9c6f1ce6ced5eb4(XmlTextReader xb9763b0038341e6c) à Aspose.Cells.OpenXML.x7661ca2b53df3da9.x5b9fbbb55c31a1b7(XmlTextReader xb9763b0038341e6c) à Aspose.Cells.OpenXML.x7661ca2b53df3da9.x06b0e25aa6ad68a9(XmlTextReader xb9763b0038341e6c) à Aspose.Cells.OpenXML.x9d49ab444acbddce.x72bde2882aefe5af(x1f5f0dd7560ed867 xd9171314ec0b2957, String x7d11dcd405070662) à Aspose.Cells.OpenXML.x9d49ab444acbddce.xc3266f78bb6c4216(x1f5f0dd7560ed867 xd9171314ec0b2957, String x7d11dcd405070662) à Aspose.Cells.OpenXML.x9d49ab444acbddce.x88ae89d546ee9fdf() à Aspose.Cells.Workbook.Open(Stream stream, FileFormatType type) à Aspose.Cells.Workbook.Open(String fileName) à xlsx2Db.FileProcess.openFile()
Please try the attached latest version of Aspose.Cells. We tested your issue with this version and it works fine. Please check it and let us know if it works fine for you too. If you still face any problem, please share your template file with us and we will check it soon.
I have tested using your code with your file, it works fine with the attached version. Please try the attached version/fix, if you still find the issue, kindly post your template (input) excel file here, we will check it soon.
We have fixed your mentioned issue in the latest release. Please try it and let us know if you still find the issue.
Note: Just for your knowledge, in the new release v4.8.0, we have merged Aspose.Grid suite to Aspose.Cells for .NET msi installer as Aspose.Grid would be no longer offered as a separate product now. You need to install the installer (uninstall older one first if you have) and use only Aspose.Cells.dll library in your project for your need. You may also take advantage using Aspose.Cells Grid suite though.