Questions tagged [hssf]

HSSF provides Java APIs to read / write Microsoft Excel 2003 and before (.xls) files. This tag should be used for questions about accessing Excel 2003 files from Java applications. HSSF is managed under the Apache POI Project.

HSSF provides Java APIs to read / write Microsoft Excel 2003 and before (.xls) files. This tag should be used for questions about accessing Excel 2003 files from Java applications. HSSF is managed under the Apache POI Project.

More information on HSSF, the bug tracker and download links are available from http://poi.apache.org/spreadsheet/index.html

If you are starting with Apache POI, you may find the Busy Developer's link very useful: http://poi.apache.org/spreadsheet/quick-guide.html

117 questions
1
vote
2 answers

how to replace multiple arrayList to single Collection Java

I am writing this utility code which dumps excel sheet into database (postgres in this case). I used poi's HSSF technique to deal with the excel sheet. I am storing each column of excel sheet into separate ArrayLists of type String. In this case…
Er. Junaid
  • 33
  • 1
  • 5
1
vote
1 answer

PHP with JavaBridge: POI setting custom background color

can anyone find what's wrong with code ? $workbook = new java("org.apache.poi.hssf.usermodel.HSSFWorkbook"); $cellStyle = $workbook->createCellStyle(); $palette = $this->workbook->getCustomPalette(); $palette->setColorAtIndex(0x40, 0, 102,…
Ben
  • 188
  • 2
  • 16
1
vote
0 answers

Add Border for merged rows and columns in HSSFCellStyle not working in Windows

I generated an excel sheet, applied styles and added border for each…
Woody
  • 930
  • 9
  • 23
1
vote
2 answers

using HSSF to read an excel file

Emp ID Name Salary 1.0 john 2000000.0 2.0 dean 4200000.0 3.0 sam 2800000.0 4.0 cass 600000.0 I have created this code: import java.io.File; import java.io.FileInputStream; import java.util.ArrayList; import java.util.Iterator; import…
userefoikon
  • 39
  • 2
  • 3
  • 7
0
votes
0 answers

HSSF POI delete existing excel file

Good morning guys, i currently have the need to validate an existing excel file, and delete it if it exist already, to create a new one. I currently have the excel creation and population of cells/rows working, all i need is to validate that. The…
0
votes
1 answer

Optimize Apache POI .xls file append

Can someone please let me know if there is a memory efficient way to append to .xls files. (Client is very insistent on .xls file for the report and I did all possible research but in vain) All I could find is that to append to existing .xls, we…
HeXMaN
  • 113
  • 1
  • 11
0
votes
1 answer

SetMargin in RPGLE on iSeries (HSSF Scott Klement Java)

i use the HSSF Excel-Tool from Scott Klement on iSeries. I try to setup the Margins on my Excelfile to Print my Excel with smaller margins. But the margin methods aren't in the Scott Klement HSSF as an RPGLE Prototype. My Question: How can i use the…
Marcel
  • 11
  • 3
0
votes
0 answers

how to save previous hssf cell value inn android studio?

HSSFWorkbook hssfWorkbook = new HSSFWorkbook(); HSSFSheet hssfSheet = hssfWorkbook.createSheet(); HSSFRow hssfRow = hssfSheet.createRow(0); HSSFCell hssfCell = hssfRow.createCell(i); …
0
votes
2 answers

How to store directly data in Apache POI XLS?

I use Apache POI HSSF API for Java to generate a long long report as XLS file. The problems is date is really large and my memory fails before calling wb.write(out);. So I wonder if there is some way directly or periodically to store the information…
Vasilen Donchev
  • 975
  • 4
  • 14
  • 26
0
votes
1 answer

Apache POI 4.1.2 Migration issue with CELL_TYPE_NUMERIC

I had POI 3.17 before in my project and as the black duck scan resutl was shwoing vulnerability I had to switch to 4.0 or better. After I downloaded the 4.1.2 jar ( THIS IS A ANT PROJECT). I am having build issues which says this : Compiling 500…
Ayman Akief
  • 1
  • 1
  • 3
0
votes
0 answers

How to add QuotePrefix in Apache poi version 4.0.1 hssf

I'm using Apache POI version 4.0.1. I want to set setQuotePrefixed(true) for my cell style. But I couldn't find this method in Hssf workbook cellstyle. Is there a way to do this? CellStyle style = setStyle(workbook, font); private CellStyle…
user8847697
0
votes
0 answers

Unable to read cell value from excel sheet using HSSF workbook in Java

I have an excel sheet with following dummy data UID ROLL NO. NAME 16004 1 fgh 16005 2 fhg 16006 3 dfg 16018 4 dfgdf 16029 5 sd I have written a code that reads the data from excel and…
Pawan
  • 423
  • 6
  • 28
0
votes
1 answer

Start the table from a specific column excel apache poi

I'm having a problem in excel while using Apache POI. I can create rows, but sometimes I'm in a situation where I would like to start from a particular column only. So is it possible to start any particular column like the 'C' column Instead of the…
Hachem
  • 1
  • 5
0
votes
1 answer

How to import both xls and xlsx files using java in spring mvc

In this method i used xssf class which is used to read xlsx file but we cant do it for xls file.for xls we need to have Hssf class .User can import any format there .My requirement,Is there any Class that can be used instead of xssf and hssf to…
Guvaliour
  • 397
  • 1
  • 5
  • 17
0
votes
1 answer

Unable to read cell color of an xls file using Apache POI

import org.apache.poi.ss.usermodel import org.apache.poi.hssf.usermodel.HSSFWorkbook; // Assume this method is wrapped in a class public static void parseFile(){ // File Path has a .xls extension FileInputStream file = new…
ShadyBears
  • 3,955
  • 13
  • 44
  • 66