Home Forums Chart Support Format time for viewportMinimum & viewportMaximum Reply To: Format time for viewportMinimum & viewportMaximum

#28926

@prashanth2303,

X axis’s viewportMinimum and viewportMaximum can either be a numeric or a Date Object. The value being passed by you seems to be invalid as it’s neither numeric nor date-time object. Passing viewportMinimum and viewportMaximum with a valid date object according to your requirements should work fine in this case. You can refer to the code snippet below for an example on the same.

viewportMinimum: new Date(2019, 01, 01, 09, 00, 00),
viewportMaximum: new Date(2019, 01, 01, 12, 30, 00)

If you are still facing the issue, kindly create a JSFiddle reproducing the issue you are facing and share it with us so that we can look into the code, understand the scenario better and help you out?


Shashi Ranjan
Team CanvasJS