I searched for a while and have not yet found a solution.
This question was asked before, but the OP did not receive an answer, and I did not want to revive the old thread, so I decided to ask a new question. Stream OP here .
The problem I am facing is that I have a spreadsheet that is created with data retrieved from the database, however sometimes the data in the cells can be quite long, so it requires the POI to be automatically sorted in order to save the user this but since I install the autofilter before calling autosize, it doesn’t quite work.
I am using Apache POI 3.9.
I either get to the point where it is authorized, but does not take into account the arrow of the autofilter drop-down list, or I get an exception with a null pointer.
I tried moving the for loop all over the place, including at the end, where the data is written to the spreadsheet, as well as immediately before the file output stream, but to no avail.
I also tried using a few different fonts, but that didn't work either.
Hope someone can help me.
thanks
Chris source share