Hi All,


I found this strange behavior in the line chart when formating the label:

Without format:


Label formated:



The labels aren't aligned with the graphic and it loses part of the line.


Bug or incorrect usage of the FormatDateTime ? (Personal Area)


Regards,

Duarte

Hi Duarte!

I tried replicating the Label that you have with my own test Line Chart and the FormatDateTime parameters you have selected works.


As for the missing portion of the red line in your chart, have you tried other FormatDateTime formats to see which of those affects that portion of the line?

I have noticed that the missing portion of the red line is above the position of the chart's Legend.

Best regards,
Joseph Enriquez

Solution

Hi Duarte,

Though I cannot readily explain why some data is missing, the main problem is that though "Label" is of data type Text, when it contains a date or date/time, the Platform recognizes it as such and instructs Highcharts (the underlying chart library) to use a date/time series. Because of your formatting, the Platform no longer recognizes it as a date or date/time, and uses text labels, like for a column chart. I think what you want is to keep the label a recognizable date/time, and use the Highcharts dateTimeLabelFormats formatting option to format your label (example here).

Solution

Kilian Hekhuis wrote:

Hi Duarte,

Though I cannot readily explain why some data is missing, the main problem is that though "Label" is of data type Text, when it contains a date or date/time, the Platform recognizes it as such and instructs Highcharts (the underlying chart library) to use a date/time series. Because of your formatting, the Platform no longer recognizes it as a date or date/time, and uses text labels, like for a column chart. I think what you want is to keep the label a recognizable date/time, and use the Highcharts dateTimeLabelFormats formatting option to format your label (example here).

That's the trick. Thanks!


Glad I could be of help :). Happy coding!