Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
datanibbler
Champion
Champion

Slider object - can I make that "return to 0" with a change of dimension?

Hi,

I have a Chart that is controlled by a slider_object: The Chart has the dimensions "Month", "CW", "Day" and "Hour" stacked into each other - when I select one or several month(s), the Dimension "CW" becomes active and so on.

The slider_object has dynamic min and max values, depending on what values (of the Expression) are effectively there within the limitations of the currently active Dimension.

=> my issue now is that the slider does not return to 0 on ist own when the user changes the Dimension - when the user selects to see only the months where the Expression surpasses a certain tréshold and then selects one or two of those months - the Dimension changes to "CW", but the slider stays where it is and in the worst case, there is no week to Display (where the value of the Expression exceeds that value).

Is there some way I can make the slider return to 0 when the Dimension changes (I can identify when that happens)?

Thanks a lot!

Best regards,

DataNibbler

6 Replies
Miguel_Angel_Baeyens

You can set a trigger in the document for the field Dimension when OnChange the variable that shows the minimum value in the slider is restored to its original minimum value.

datanibbler
Champion
Champion
Author

Thanks Miguel!

I will try that. That should work.

datanibbler
Champion
Champion
Author

One more question .- what does a field_Event_Trigger do when I use the button "on Change"? What does that mean? I guess in this instance I don't Need it, the user can only select one or several month(s) and then the Chart Switches to the Dimension "calweek". Still - in which Scenario would I use that?

Thanks a lot!

Best regards,

DataNibbler

datanibbler
Champion
Champion
Author

Hi Miguel,

I have an issue with that: It doesn't work yet. The Thing is, the Minimum value of the variable which is controlled by the slider is not always 0 - it is a variable Minimum that depends on the currently active Dimension of the Chart which in turn depends on the selections of the user.

- At first, the Dimension is "month";

- When the user selects one/ several month(s), the Dimension is "calweek";

- Beneath that Level, there are two more dimensions;

- The Minimum value of the variable and of the slider is always the smallest displayed value of the Expression, calculated with an min(aggr()) function.

-> So I added a field_Level_Trigger for the field which is the first Dimension, said "on select" and Chose to "set a variable" and the value to set it to is the result of that min(aggr()) function - so do I have to use an equals-sign in the Settings for the Trigger?

Up to now, however, that did not work, the variable always stays where it is when I Change dimensions.

datanibbler
Champion
Champion
Author

Oops - I added one line in a TextBox to see the current value of the variable and it seems that the variable is indeed reset to the min value when I select a month - only the slider_object does not react to it, the needle still remains where I put it.

Is there a way I can refresh that?

Miguel_Angel_Baeyens

It's working for me, the minimum value in the slider goes to 0