We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Excel can only be rendered as JPEG

Using the code below, I should be able to create a BMP file from an Excel worksheet, but in fact it only works for the JPEG case. All other file formats fail. I am using aspose-cells-7.0.3-java.

void test() throws Exception {
m_workbook = new Workbook("C:\\Users\\Bruce\\Desktop\\PFI_test_cases.xlsx");
ImageOrPrintOptions options = new ImageOrPrintOptions();
Worksheet worksheet = m_workbook.getWorksheets().get(0);
SheetRender render = new SheetRender(worksheet, options);
FileOutputStream outputStream = new FileOutputStream("C:\\Users\\Bruce\\Desktop\\Test.bmp");
render.toImage(0, outputStream);



I can find the issue: “Exception in thread “main” java.lang.UnsupportedOperationException: setPosition() is not supported. …” when using your code with a simple template file.

I have logged a ticket with an id: CELLSJAVA-40046. We will look into it soon.

Thank you.

Please try the attached version/fix: v7.0.3.3.

We have fixed the issue.

Thank you

The issues you have found earlier (filed as CELLSJAVA-40046) have been fixed in this update.

This message was posted using Notification2Forum from Downloads module by aspose.notifier.