Problem exporting Date to Cell #1538
Labels
No Label
DBF
Dates
Defined Names
Features
Formula
HTML
Images
Infrastructure
Integration
International
ODS
Operations
Performance
PivotTables
Pro
Protection
Read Bug
SSF
SYLK
Style
Write Bug
good first issue
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sheetjs/sheetjs#1538
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
After reading the documentation, we discovered that we can get a cell reference by using:
cellref = XLSX.utils.encode_cell({ c: col, r: R });
With that variable mentioned before, cellref, we can get into it's properties like .v for value, .s for style and .t for type, and we been informed by e-mail that we can also access .z, witch receives a string and we need to setup a value for it in order to date to work correclty on excel.
Our real problem is that we been strugling to get it work for type (.t) of date ('d'). We tried to apply a date value treated as DD/MM/YYYY or MM/DD/YYYY and both of them got a final result on excel modified, with a different date. I used console.log() to get the value from cellref.v the last moment I had access to it and the date was with the correct value, but in Excel file it usually had one day less. We tried another approach to solve this out, that was to give on the .v a value as a Serial Number Value, that excel accepts and converts do Date. I managed to get a working function that calculates the value. If I get that value from console.log and paste on Excel field with type Date, the number is correclty converted into the corrected date. But when using the XLSX application, giving the .v that serial number value does not work and the date shown to me is 12/31/1969, witch is a default date for invalid date problem.
On the contact via e-mail I got informed to open a Ticket here for further support. I also don't really get what value I must assign to .z in other to get it work. Also, if any of you give me the right solution, please tell me if that should be applied with Serial Number value or just a Date pattern from JavaScript.
Thank you
Any answer on that ?
Thank you