How to disable the automatic parsing of date/time values #1141
ghost
started this conversation in
API Questions
Replies: 1 comment 5 replies
-
Hi @jamshaid-tariq-geekybugs, thanks for reaching out to us! Strings that can be parsed as dates according to dateFormats are automatically converted to
const data = [[
//...
"'02-01-2021",
//...
]]
const hf = HyperFormula.buildEmpty({
licenseKey: "internal-use-in-handsontable",
dateFormats: [],
}) Alternatively, you may let HyperFormula store the dates in const data = [[
"02-01-2021",
"=TEXT(A1, "MM-DD-YYYY")"
]] Please, let me know if one of these methods solves your problem. |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
I have a hyperFormula instance.
I am adding a sheet and setting its content to array of array.
Steps to reproduce
when I getCalculated values hf.getAllSheetsValues(). It is converting dates into timestamp i guess but dates are in string.
Below is demo, click on getValues button and check data in console. dates are changing to number. Problem is I dont have handsontable instance to set cell type. I just have hyperformula instance.
I have changed DateFormate to Us as well as Europe both are changing the date to timestamp.
Demo
https://jsfiddle.net/1uscqvL2/8/
Beta Was this translation helpful? Give feedback.
All reactions