0

I'm using JExcel API to open and edit an existing .xls file.

First problem was that I can't directly edit the opened xls file. I need to make a copy of that first. (Question1: It is possible to edit the opened workbook or not?)

My solution to that based on some internet information was:

Workbook workbook=Workbook.getWorkbook(inputfile);
...
WritableWorkbook wb=Workbook.createWorkbook(inputfile, workbook);
wb.write();
wb.close();
//Edit cells in wb

This works but the updated version of the xls has the wrong formatting. So, Question 2: Is there any way to keep the format when I copy workbooks?

João Pereira
  • 673
  • 1
  • 9
  • 29

1 Answers1

0

Well, I solved it by using Apache API.

Even though it is not as well documented as JExcel it seems to do its job better.

João Pereira
  • 673
  • 1
  • 9
  • 29