Home forums Using CanvasJS Broken date/time Reply To: Broken date/time

#26085

@andenjs,

For one thing, I apparently need to append “000” to Unix timestamps? Otherwise, they are wrong. Is that right?

Unix Timestamp is the number of seconds that has elapsed since January 1, 1970 whereas JavaScript timestamp is the number of milliseconds that has elapsed since January 1, 1970. Multiplying unix timestamp by 1000 gives you JavaScript timestamp.

Second, the example I was looking at has the X-axis format under data. However, this doesn’t work

xValueFormatString is used to define the the format of x-value that appears in toolTip and indexLabel whereas valueFormatString is used to define the format of the value that appears in axis. Setting valueFormatString should work fine in your case.


Vishwas R
Team CanvasJS