# Dynamic max for ui dashboard slider node

**URL:** <https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017>\
**Category:** General\
**Created:** [22 October 2019 14:56 UTC](https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017 "2019-10-22T14:56:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rtholl](https://avatars.discourse-cdn.com/v4/letter/r/45deac/32.png) [@Rtholl](https://discourse.nodered.org/u/Rtholl)\
**Post date:** [22 October 2019 14:56 UTC](https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017/1 "2019-10-22T14:56:26Z")

</div>

Hey guys,

Is there a way to feed the ui dashboard slider node an integer for the maximum value? My idea is to take the length of an array and feed this as the maximum of the slider node. Something like:

"msg.ui\_slider.max = array.length;"

and this would dynamically control the slider node's maximum value.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [22 October 2019 15:22 UTC](https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017/2 "2019-10-22T15:22:45Z")

</div>

Yes indeedy...

> <https://github.com/node-red/node-red-dashboard/blob/master/config-fields.md>

---

<div class="post-metadata">

**Author:** ![Rtholl](https://avatars.discourse-cdn.com/v4/letter/r/45deac/32.png) [@Rtholl](https://discourse.nodered.org/u/Rtholl)\
**Post date:** [22 October 2019 17:26 UTC](https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017/3 "2019-10-22T17:26:38Z")

</div>

Thanks, this worked perfectly!  
I didn't find any option to tag this post as "solved" or "completed" but it is 🙂

---

<div class="post-metadata">

**Author:** ![hexfet75](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hexfet75/32/43224_2.png) [@hexfet75](https://discourse.nodered.org/u/hexfet75)\
**Post date:** [31 December 2021 07:12 UTC](https://discourse.nodered.org/t/dynamic-max-for-ui-dashboard-slider-node/17017/4 "2021-12-31T07:12:21Z")

</div>

Sorry but I don't exactly understand how use.. it's possible put an example?
