Questions tagged as 'apache-poi'

1
answer

Euro word symbol

I have the following code: XWPFParagraph totalFinal = documento.createParagraph(); XWPFRun tileFinal = totalFinal.createRun(); tileFinal.setText("TOTAL: " + totalIVA + " (€) "); When I generate the word, I get a weird symbol     
asked by 20.11.2017 / 16:42
1
answer

Read excel with Apache POI in java by column name

Good afternoon experts, I have a problem with a project that consists of reading an excel file and validating the data by columns, I have managed to read the file without problems and also validations (through regular expressions) through the li...
asked by 10.03.2016 / 00:39
1
answer

How to create headers in word with Apche POI?

I have this code: XWPFParagraph title = document.createParagraph(); XWPFRun run = title.createRun(); title.setAlignment(ParagraphAlignment.CENTER); String imgFile = "C:\Users\Leath\Documents\NetBeansProjects\usuario_1\src\imagenes\encabeza...
asked by 10.08.2017 / 18:41
1
answer

How to know with Apache POI and java if a column in excel is hidden?

Hi, I'm importing excel files with extension xls and xlsx but my doubt is how to detect if the column of a cell is visible or hidden, thank you in advance for your response.     
asked by 30.10.2016 / 04:41
1
answer

POI reading decimals

I have an excel *.xlsx with a cell of type Número , the value I have in the excel is 0,0794497914814776 but the value returned by the method celda.getNumericCellValue() is: 0,07944979148147759987 I have tried...
asked by 07.06.2018 / 12:17
2
answers

Delete or catch html style in POI

I have the following: String cadena="<ul><li>test &nbsp;</li><li>test 2</li></ul>" HSSFCell cell = row.createCell((short)0); cell.setCellValue(cadena) I would like the cell to take the html format or...
asked by 03.05.2017 / 10:19
1
answer

Go through all the sheets of an excel - With JAVA and POI

Good day, I have a functionality that replaces the text of some cells in an Excel document, so far it works, but I ran into a problem, when they are excel files that have more than one sheet per book, only the first one runs through the first sh...
asked by 17.11.2016 / 14:36
2
answers

NullPointerException when using getSheet ()

I am trying to edit an excel file with apache poi in the following way: public void generarOrdenDePago(Cliente cliente, Periodo periodo, OutputStream outputStream) { try { InputStream in = new FileInputStream("ordenPagoLimpia.xls...
asked by 30.03.2017 / 21:33
1
answer

Configure ViewResolver with Spring4

Good morning everyone. I am developing an application with Spring4 and Maven in Java. And I want to add an option to export the data of a table to an excel sheet, using Apache POI. The problem is that I do not recognize well the mapping...
asked by 15.11.2017 / 12:45
2
answers

Styles API POI

I have: CellStyle style = sheet.getWorkbook().createCellStyle(); HSSFCell cell = row.createCell((short)number); cell.setCellValue(text) cell.setCellStyle(style); I would like the background to be gray, for example     
asked by 28.04.2017 / 12:32