https://bz.apache.org/bugzilla/show_bug.cgi?id=66431
Bug ID: 66431
Summary: Microsoft PowerBI Desktop can't open spreadsheet
created by poi
Product: POI
Version: 5.2.2-FINAL
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: XSSF
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
Microsoft PowerBI Desktop https://powerbi.microsoft.com/en-us/downloads/
can't open spreadsheet created by poi (error message: file is corrupted)
spreadsheet genertor:
package testpoi;
import java.io.*;
import org.apache.poi.xssf.streaming.SXSSFSheet;
import org.apache.poi.xssf.streaming.SXSSFWorkbook;
import org.apache.poi.xssf.usermodel.*;
public class testpoi {
public static void main(String[] args)throws Exception {
//Create Blank workbook
SXSSFWorkbook wb = new SXSSFWorkbook(new
XSSFWorkbook(XSSFWorkbookType.XLSX), -1, true);
SXSSFSheet currentSheet = wb.createSheet();
wb.setSheetName(0, "Test tab");
//Create file system using specific name
FileOutputStream out = new FileOutputStream(new
File("workbook.xlsx"));
//write operation workbook using file out object
wb.write(out);
out.close();
System.out.println("workbook.xlsx written successfully");
}
}
When I open workbook.xlsx in Excel, save (without any modification), PowerBI
open it with no error.
Best Regards
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]