poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oliver Hirschi" <ohirs...@pm-medici.ch>
Subject newline in an excel cell
Date Mon, 10 Jan 2005 14:36:10 GMT

I have a problem with newlines in a excel-cell. the excel is generates
with apache POI HSSF.

I tried several things:
1. cell.setCellValue("First Line\nSecondLine");
2. cell.setCellValue("First Line\rSecondLine");
3. cell.setCellValue("First Line\r\nSecondLine");

If I take variant 1, after opening the genearted xls with excel, the
newlines are shown as squares. After double-clicking onto the cell, the
newlines are okay.

How can I make correct newlines with poi, that are shown correct by
opening the file with excel?

Oliver Hirschi

To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List:     http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project:  http://jakarta.apache.org/poi/

View raw message