You must be logged in to post your query.
Home › Forums › Chart Support › Show current time in X axis in stackedcolumn
Here is my code – https://codepen.io/adjmpw/pen/ZMMGpY , When i set following code in x axis , column charts becomes invisible ,whereas it works fine if its 1,2,3
xVal = new Date(); dps.push({ x: xVal, y: yVal });
@adjmpw,
It seems to be working with date-time axis aswell.
Can you kindly create JSFiddle or in Codepen – reproducing the issue you are facing, so that we can look into your code, understand the scenario better and help you out?
— Vishwas R Team CanvasJS
I made it working by keeping label as current time , its not working if i add time to X axis
try adding xValueType: “dateTime”, in data to replicate my issue , thanks..https://codepen.io/adjmpw/pen/eLLxLZ
X-Value can either be numeric or a dateTime value. But in the pen that you have shared x-value seems to be string as curTime() returns a string. You can use labels instead of x-value in this case. Please take a look at this updated pen.
curTime()
You must be logged in to reply to this topic. Login/Register