# PLutoUI -- Can I make a Slider With a Text Box Option

**URL:** <https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194>\
**Category:** Visualization\
**Created:** [July 28, 2023, 12:16pm UTC](https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194 "2023-07-28T12:16:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Allan\_Baker](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/allan_baker/32/42645_2.png) [@Allan\_Baker](https://discourse.julialang.org/u/Allan_Baker)\
**Post date:** [July 28, 2023, 12:16pm UTC](https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194/1 "2023-07-28T12:16:28Z")

</div>

In a Pluto Notebook, I would like to have a value driven by a slider, but I would also like the option to override that slider value with a text input. Or have them linked in someway.

Any thoughts on how to accomplish this?

Best Regards,

---

<div class="post-metadata">

**Author:** ![mthelm85](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mthelm85/32/224164_2.png) [@mthelm85](https://discourse.julialang.org/u/mthelm85)\
**Post date:** [July 28, 2023, 1:46pm UTC](https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194/2 "2023-07-28T13:46:21Z")

</div>

What would the override/link logic look like? Here’s an example that just checks the value of the slider variable and returns either that value or the value of the text variable:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/b/8/b869cbe9bd83a006874af8448880ba386613c5ce.png)

I’m assuming you need more complex logic?

---

<div class="post-metadata">

**Author:** ![Allan\_Baker](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/allan_baker/32/42645_2.png) [@Allan\_Baker](https://discourse.julialang.org/u/Allan_Baker)\
**Post date:** [July 28, 2023, 1:50pm UTC](https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194/3 "2023-07-28T13:50:33Z")

</div>

I guess I need a way for the user to be able to type a number to jump the slider to the value typed. Perhaps it could be mechanized with the “default” value being a variable itself… but it seems like there needs to be a little bit of a circular loop here if the objects are separate. I didn’t know if you could use “combine” some way to combine a slider and a text box, so if one was updated, it could update the other. Then basically, the last one updated would win. If the reader wanted to type a number, they could. If they wanted to grab the scrollbar they could. They would both feed the same variable somehow.

---

<div class="post-metadata">

**Author:** ![mthelm85](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mthelm85/32/224164_2.png) [@mthelm85](https://discourse.julialang.org/u/mthelm85)\
**Post date:** [July 28, 2023, 1:55pm UTC](https://discourse.julialang.org/t/plutoui-can-i-make-a-slider-with-a-text-box-option/102194/4 "2023-07-28T13:55:30Z")

</div>

How about this?

 ![image](https://global.discourse-cdn.com/julialang/original/3X/0/a/0ab5ed4a90844a2e4a9985a6637f2c3e764b6197.png)
