Free Support Forum - aspose.com

Saved Excel file reports repair problem pop-up when opening (#1794)

Hello,

after executing the given code, warning and repair message pop-up on opening saved excel file. Can you help me with this? I am using aspose.cells for java 17.11.0 version.

Workbook workbook = new Workbook("UroborosCL_PIP_01_Basic.xlsx");
Font font;
WorksheetCollection worksheets = workbook.getWorksheets();
for (Object o1 : worksheets) {
    Worksheet worksheet = (Worksheet)o1;
    Cells cells = worksheet.getCells();
    for (Object o2 : cells) {
        Cell cell = (Cell) o2;
  	if (cell.getType() == CellValueType.IS_STRING && !cell.isFormula()) {
	    font = cell.characters(0, cell.getStringValue().length() - 1).getFont();
	} else {
	    font = cell.getStyle().getFont();
	}
    }
}
workbook.save("UroborosCL_PIP_01_Basic-aa.xlsx");

UroborosCL_PIP_01_Basic.xlsx.zip (504.1 KB)

Regards,
Zeljko

@Zeljko,

Thanks for your query.

I have tested this sample code using latest version Aspose.Cells for Java 18.7.6 but no issue is observed. Please download the following version, test the sample code again and share the feedback.

Aspose.Cells for Java 18.7.6.

Hi,

I tested the scenario with latest aspose.cells version and it works fine now. Thank you for help.

Regards,
Zeljko

@Zeljko,

Good to know that your issue is sorted out by using the latest version. Feel free to contact us any time if you need further help or have some other issue or queries, we will be happy to assist you soon.