Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Apache Poi set Date Format on a column

Reply
Thread Tools

Apache Poi set Date Format on a column

 
 
ponzetta@gmail.com
Guest
Posts: n/a
 
      10-03-2005
Hi, I use Apache Poi to read/write from/to Excel.

I'm try to set a column of a sheet to show all values with correct
format "m/d/yy"

I'm used:

HSSFCellStyle cellStyle = wb.createCellStyle();
cellStyle.setDataFormat(HSSFDataFormat.getBuiltinF ormat("m/d/yy"));
HSSFCell cellaData = row.createCell(new Integer(0).shortValue());
cellaData.setCellStyle(cellStyle);
cellaData.setCellValue(data);

This works fine, but format all cells of sheet and with much rows excel
return a warning.
I'm serching a method to format column entire.

Thank's Lorenzo

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache POI - Export Date-Time data Fici Java 0 02-25-2008 09:47 AM
Apache POI, ExcelSheet & Jar... julielaurek@gmail.com Java 9 07-17-2007 04:28 PM
Apache POI to generate Excel 97 files? mmellinger66@gmail.com Java 0 11-17-2006 04:58 AM
APIs similar to Apache POI anand Java 0 06-05-2006 08:17 AM
Apache POI Question Si Java 1 12-17-2004 12:10 PM



Advertisments