[Bug 60651] New: Auto filter crashes excel when sorting

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[Bug 60651] New: Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

            Bug ID: 60651
           Summary: Auto filter crashes excel when sorting
           Product: POI
           Version: 3.15-FINAL
          Hardware: PC
            Status: NEW
          Severity: normal
          Priority: P2
         Component: HSSF
          Assignee: [hidden email]
          Reporter: [hidden email]
  Target Milestone: ---

Created attachment 34681
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=34681&action=edit
This is the file that crashes.

I am having a crashing issue with excel after I add a auto filter thru java.
After adding the filter to excel columns if I open the excel sheet and attempt
to sort, using the drop down arrow on the column header, it crashes every time.
If I first filter, like unchecking the blanks option from the drop down, then I
can sort and use the sheet like normal with no crashes. If I try to sort using
the Sort & Filter button in the editing section at the top of excel it will
sort just fine but remove the auto filter. Also if I remove and re-add the
filter it doesn't crash and works as expected. Is there a way to make it to
where we can add the auto filter thru java then be able to sort before making
any other changes to the sheet? I have pasted my code below and I have attached
both the excel sheet that is create thru java and pre and post fixing it.


FileInputStream fileIn = new FileInputStream("C:\\Users\\gria\\Desktop\\Fleet
Manager Summary.xls");
                        HSSFWorkbook report = new HSSFWorkbook(fileIn);

                        Sheet sheet = report.getSheetAt(0);
                        sheet.setAutoFilter(CellRangeAddress.valueOf("A5:O5"));

                        FileOutputStream fileOut = new
FileOutputStream("C:\\Users\\gria\\Desktop\\Fleet Manager SummaryT.xls");
                        report.write(fileOut);
                        report.close();
                        fileOut.close();
                        fileIn.close();

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 60651] Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

--- Comment #1 from Ardel Grider <[hidden email]> ---
Created attachment 34682
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=34682&action=edit
This is the file where I removed and added the auto filter

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 60651] Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
In reply to this post by Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

Nick Burch <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All

--- Comment #2 from Nick Burch <[hidden email]> ---
If POI is generating a file that Excel gives warnings or errors about, that's
something to report here first

If POI is generating a file that makes Excel crash, then that's something you
need to report to Microsoft! They generally are quite keen to make fixes that
avoids their software crashing, especially as some crashes may turn out to have
security implications above and beyond the DoS effects of the crash.

We can certainly take a look at the issue on the POI side, especially if we can
find out what specific bit Excel dislikes, but talking to Microsoft needs to be
your top priority here!

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 60651] Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
In reply to this post by Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

--- Comment #3 from Ardel Grider <[hidden email]> ---
Thank you for the quick reply. I have went to Microsoft's community page and
posted about the crash as of now. Link:
https://answers.microsoft.com/en-us/msoffice/forum/msoffice_excel-mso_other/why-is-this-excel-file-created-from-my-java-code/358e5a35-db8d-46cc-96ed-b9252a29c526?tm=1485456007886

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 60651] Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
In reply to this post by Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

buch0 <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email],
                   |                            |[hidden email]

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 60651] Auto filter crashes excel when sorting

Bugzilla from bugzilla@apache.org
In reply to this post by Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=60651

Dominik Stadler <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |INVALID
             Status|NEW                         |RESOLVED

--- Comment #4 from Dominik Stadler <[hidden email]> ---
We cannot prevent Excel from crashing here and it is hard to find out what
exactly triggers the crash.

As far as we see Apache POI is writing the format correctly here, also
LibreOffice correctly opens and sorts this document.

If this is still an issue you likely need to use more official Microsoft
support channels where you receive more responses.

Overall I don't see anything that can be done in Apache POI right now.

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]