ravindersinghblujay / tableexport-for-vaadin

Automatically exported from code.google.com/p/tableexport-for-vaadin
0 stars 2 forks source link

Please add the ability to export java.util.Date types correctly #3

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Please add the ability to export java.util.Date types correctly. Right now, 
they get exported as float values, and there is no way to specify a format for 
the Excel cell.

Posted at: http://vaadin.com/directory#addon/tableexport

Original issue reported on code.google.com by jnas...@gmail.com on 10 Sep 2011 at 1:26

GoogleCodeExporter commented 9 years ago
Now handles dates properly.  Previously was not handling them.  

To set the default dateFormat, override the method:

protected short defaultDateDataFormat(final Workbook wb) {

For doubles, there is a corresponding method:

protected short defaultDoubleDataFormat(final Workbook wb) {

Alternately, after creating the ExcelExport but before calling convertTable, 
user can   use methods:

    public void setDateDataFormat(final String excelDateFormat) {
    public void setDoubleDataFormat(final String excelDoubleFormat) {

Original comment by jnas...@gmail.com on 17 Sep 2011 at 7:20