Questions tagged [hssfworkbook]

High level representation of a .xls workbook, top level object for creating new sheets

High level representation of a .xls workbook, top level object for creating new sheets

72 questions
8
votes
1 answer

Is there any alternate way to avoid deprecation in Apache POI, for HSSF built-in colors?

In my code i want to change the cell colors of a particular column of a HSSFWorkbook, if the text is "PASS". But when i was writing the code, lots of methods and constants like BRIGHT_GREEN.index, setFillPattern, SOLID_FOREGROUND are deprecated. I…
BongCule
  • 115
  • 1
  • 2
  • 9
4
votes
4 answers

android ExceptionInInitializerError Caused by Unable to determine record types while new HSSFWorkbook(inputStream)

Getting error E/AndroidRuntime: FATAL EXCEPTION: AsyncTask #1 java.lang.RuntimeException: An error occured while executing doInBackground() at android.os.AsyncTask$3.done(AsyncTask.java:299) at…
Shirish Herwade
  • 11,461
  • 20
  • 72
  • 111
3
votes
0 answers

Problems when converting XSSFWorkbook to SXSSFWorkbook APACHE POI

I'm triying to convert a xssfWorkbook file to a SXSSF because I'm generating a big report, but the problem is that I cannot convert, what I'm currently trying is this example. public void export(Workbook hssfWorkbook, Map model)…
Ivan Cuellar
  • 31
  • 1
  • 2
3
votes
1 answer

android apache poi error

here is my code for generating backup for my database i using apache poi for that purpose but it show some errors when i execute. i start with HSSF worksheet and create a sheet and add details from my database and save that file in the specific…
Shellz
  • 99
  • 1
  • 14
2
votes
3 answers

Getting date in double format 43318.4847916667 instead of 06-08-2018 11:38:06

I am writing a java code to generate an excel file using HSSFWorkbook(.xls). I need to write date in one column in this format 06-08-2018 11:38:06 but it is generating like this 43318.4847916667. Here is the code snippet i used. Please help me how…
Anam Qureshi
  • 161
  • 2
  • 8
2
votes
0 answers

Excel created with Apache POI has dot as a decimal separator for values above 1000 and comma for smaller

I've met some problem with generating Excel files using org.apache.poi.ss.usermodel utils: Values above 1000 have dot (.) as a decimal separator and values below 1000 have comma (,) as a decimal separator. I've trying a lot of different ways put…
KamilosD
  • 333
  • 1
  • 2
  • 12
2
votes
1 answer

Excel VBA: How to combine specific worksheets from different workbooks?

I am still very new to VBA and am trying to combine certain worksheets from different workbooks. For example: I have a workbook called "One" with multiple worksheets (A,B,C,D). I have another workbook called "Two" with multiple worksheets…
cthallofamer
  • 141
  • 2
  • 14
2
votes
0 answers

XSSFWorkbook won't load a small Excel file

I've tried to initialize an XSSFWorkbook with an Excel file with the .xlsm extension using Apache POI in Java, but it's taking a lot of time to load the file (I've already waited 1 hour and it was still loading). The xlsm file itself is fairly small…
1
vote
1 answer

Mentioned date format (dd/MM/yyyy) is not working for current date in excel using Apache Poi

I need to generate excel file with date values using HSSFWorkbook(.xlsx). I am passing date value generated by Date class and also I am adding the format to the excel cell as dd/MM/yyyy using createHelper.createDataFormat().getFormat("dd/MM/yyyy")…
Prakash
  • 630
  • 3
  • 10
  • 20
1
vote
0 answers

My Android studio App is not creating XL File in download folder in all mobiles

I have created an app which takes input and produces a XL file. There are some problems which are given below: Problem 1. The file is created in the download folder of internal storage and can be seen by the file manager of droid max2 , but my…
1
vote
0 answers

Latest poi 5.2.1 version is having issue with HSSFWorkbook(fis)

I have updated poi version from 4.1.1 to 5.2.1. After upgrade I am facing issues with xls and xlsx format files. I currently have poi-5.2.1.jar, poi-ooxml-5.2.1.jar, xmlbeans 3.1.0, commons-io-2.8.0 version and commons-compress-1.21.jar. may I know…
1
vote
1 answer

How to write data into multiple sheets in same excel

I am trying to write the data into same excel file in different sheets, below is the code I tried here only one sheet is creating and data is updating in that sheet, new sheet name is overriding on old sheet. Here I am calling call method two times…
arun
  • 25
  • 5
1
vote
1 answer

Getting Out of memory when reading large excel files (.xls) using Workbook method of apache poi jxl-2.6.jar

File size is 10mb. File format is .xls I am using the Workbook class from jxl-2.6.jar file of apache poi. try { Workbook wb = Workbook.getWorkbook(filePath);//**after this line i am getting OOM** sheet =…
1
vote
1 answer

Getting java.lang.OutOfMemoryError: GC overhead limit exceeded while trying to reader a big excel file(.xlsx)

I am simply trying to read a big excel file(.xlsx) file, using the POI API and getting this exception. This is the code I am using: public static void main(String args[]) throws FileNotFoundException { File f = new…
DockYard
  • 989
  • 2
  • 12
  • 29
1
vote
1 answer

How to print two columns in excel side by side after writing all rows from the first column?

I have created code in which data is accessible through the database and then that data is written in the excel sheet. Now data is written successfully. But the issue is when the data is get written in the excel sheet at the first column of the…
1
2 3 4 5