Just as a quick follow-up, I have taken a quick look at OpenOffice Calc and
there is nothing exactly like the Custom option in Excel. There is a User
Defined option within Calc but that is blank whereas, if I remember
correctly, the Custom option in Excel contains quite a few alternative
formats for date/times. Again, if I remember correctly, Excel offers only a
very few options for formatting dates if you select the Date type whereas
Calc offers lots of different formatting options.

Just to follow up on an earlier suggestion, if you set the type of a cell to
Date explicitly using Excel and then choose a format for that cell you
should be able to change the type to Custom and see the formatting string
Excel applied displayed to you. Try copying this, using it to create a data
format in POI and then apply that to a worksheet cell. That might result in
the type being selected as Date by Excel, but as usual no promises.

PS Sorry to sound a little vague but I no longer have access to Excel, we
use OpenOffice exclusively.

--
View this message in context: 
http://apache-poi.1045710.n5.nabble.com/Set-cell-type-to-Date-tp5537937p5538079.html
Sent from the POI - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to