How can i change the label of axis.

Hi All,

Is there any way to change the label of the axis? For me, I want to add date instead of the time when the user selects a specific time/specific condition. Is there any way to add formatting to the axis label using the script? In the below image you can see by default label is showing hour data but when the user satisfies a condition it has to change and show day as well in the label. Can we do that using script?

Hi Anupam,

Based on my understanding of this use case, you want to show the data based on day level if the user makes a specific selection. In this case, I would suggest adding a hierarchy level filter and connecting it to the DateTime hierarchy.
Now you can update the value of this level filter to change the level of the hierarchy based on the user selection. Here is a sample script for this - https://www.dundas.com/support/developer/script-library/filter-and-parameter/set-hierarchy-level-parameter
Please note that in order to achieve this you will need to assign a time dimension to your dateTime hierarchy if you don’t have one already.

I hope this answers your question.