Currency format can't be used in formula #3038
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
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sheetjs/sheetjs#3038
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?
Hi,
I try to export a sheet with currency formatted cells. Based on https://github.com/SheetJS/sheetjs/issues/242#issuecomment-301882390 I set my currency format like this:
ws[cellName].z = '#,##0.00\\ "€"';
But their is something weird: cells are being recognized as a currency and can be summed by using the '+' operator but they cannot be summed by using the
SUM()
excel function (calledSOMME()
in my example because it's in french).Cells are recognized as currency:
Can someone explain me why and what should I do for being able to use formula with my currency formatted cells ?
Thank you.
You stumbled upon a quirk in Excel.
Based on the screenshots, cells A2 and A3 are text. Check your starting point and ensure you are generating numeric cells.
For example, if you are using
aoa_to_sheet
, the string"12"
will be translated to a text cell while the number34
will be a numeric cell:If you'd like a more detailed explanation of Excel's inconsistent behavior, feel free to ask in the chat