Excel Export fires NullPointerException if file dialog is cancelled [message #956121] |
Wed, 24 October 2012 08:55 |
Michi Classen Messages: 36 Registered: March 2012 |
Member |
|
|
The excel export is continuable, as long as the file dialog handler has not been cancelled. Once the dialog was cancelled, the following error message is thrown:
!STACK 0
java.lang.NullPointerException
at org.eclipse.nebula.widgets.nattable.export.FileOutputStreamProvider.getOutputStream(FileOutputStreamProvider.java:40)
at org.eclipse.nebula.widgets.nattable.extension.poi.PoiExcelExporter.getOutputStream(PoiExcelExporter.java:54)
at org.eclipse.nebula.widgets.nattable.export.NatExporter.exportSingleLayer(NatExporter.java:44)
at org.eclipse.nebula.widgets.nattable.export.command.ExportCommandHandler.doCommand(ExportCommandHandler.java:33)
at org.eclipse.nebula.widgets.nattable.export.command.ExportCommandHandler.doCommand(ExportCommandHandler.java:1)
at org.eclipse.nebula.widgets.nattable.command.AbstractLayerCommandHandler.doCommand(AbstractLayerCommandHandler.java:19)
at org.eclipse.nebula.widgets.nattable.layer.AbstractLayer.doCommand(AbstractLayer.java:152)
at org.eclipse.nebula.widgets.nattable.layer.CompositeLayer.doCommand(CompositeLayer.java:137)
at org.eclipse.nebula.widgets.nattable.grid.layer.GridLayer.doCommand(GridLayer.java:169)
at org.eclipse.nebula.widgets.nattable.NatTable.doCommand(NatTable.java:507)
I'm using the actual software released on Eclipse.org.
Looking at bugzilla, this bug was reported on May '12:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=379923 but never solved.
Ciao,
Michi
[Updated on: Wed, 24 October 2012 13:11] Report message to a moderator
|
|
|
|
|
|
Re: Excel Export fires NullPointerException if file dialog is cancelled [message #972486 is a reply to message #972423] |
Mon, 05 November 2012 17:13 |
Michi Classen Messages: 36 Registered: March 2012 |
Member |
|
|
Hi Edwin, thanks!
Do you have a patch of the fix or a fast instruction to solve the bug?
In addition I noticed another errorneous behavior on export. Running the export a second time, an empty excel sheet is saved and the following exception is thrown:
java.lang.IllegalArgumentException: This Style does not belong to the supplied Workbook. Are you trying to assign a style from one workbook to the cell of a differnt workbook?
at org.apache.poi.hssf.usermodel.HSSFCellStyle.verifyBelongsToWorkbook(HSSFCellStyle.java:801)
at org.apache.poi.hssf.usermodel.HSSFCell.setCellStyle(HSSFCell.java:905)
at org.apache.poi.hssf.usermodel.HSSFCell.setCellStyle(HSSFCell.java:901)
at org.eclipse.nebula.widgets.nattable.extension.poi.PoiExcelExporter.exportCell(PoiExcelExporter.java:113)
at org.eclipse.nebula.widgets.nattable.export.NatExporter.exportLayer(NatExporter.java:167)
at org.eclipse.nebula.widgets.nattable.export.NatExporter$1.run(NatExporter.java:54)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4140)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
This bug is also reported in bugzilla
https://bugs.eclipse.org/bugs/show_bug.cgi?id=390522
[Updated on: Tue, 06 November 2012 13:32] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.04340 seconds