42tahara / as3xls

Automatically exported from code.google.com/p/as3xls
0 stars 0 forks source link

Unable to detect localized date formatted cells #18

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. open an excel file and create a cell with this value 40025.64539621528
2. apply on excel a date formatter using localized format (the formatter
shows an asterisk before the formatter in excel, see picture attached)
3. use getCell on the cell. 

What is the expected output? What do you see instead?
The code in sheet.as that analyzes and tries to guess the cell formatter
fails detecting date and returns the number version, also forcing the date
detection fails due to the +1 in the "d.date += cellValue +1" code row.

What version of the product are you using? On what operating system?
Latest (from download section) Mac and Windows, i've checked on the svn and
the code is the same.

Please provide any additional information below.
I had to do copy and paste from the cell.as area and also remove the "+1"
from the d.date += cellvalue to let the code work flawlessy, otherwise it
was wrong regarding the day (it was some days forward).

var d:Date = new Date();
d.hours = 0;
d.minutes = 0;
d.seconds = 0;
d.milliseconds = 0;
d.fullYear = 1899;
d.month = 11;
d.date = 30;
d.date += cellValue; //removed +1

Original issue reported on code.google.com by neog...@gmail.com on 9 Aug 2009 at 6:54

Attachments:

GoogleCodeExporter commented 8 years ago

I think this issue should be fixed in my fork over at:

http://github.com/djw/as3xls

Original comment by danjwilson on 29 Oct 2009 at 4:15