Jump to content

Get the Value from the Slider Widget


Go to solution Solved by Josh,

Recommended Posts

Posted

I've searched through the widget documentation and the slider.lua, also googling every combination I can think of to no luck.

How do I get the current value of a slider widget? I've tried :GetValue(), :GetSliderValue, :GetSelectedItem() and none of them worked, with the last one always returning something like "index out of range" despite the value i'm putting in being very well within the range I defined (0, 170).

I'd also like to know how to Set the value for loading. This is for a simple FOV Slider for my options menu.

  • VoyVivika changed the title to Get the Value from the Slider Widget
  • Solution
Posted

It's just widget:SetSliderValue() and widget:GetSliderValue().

My job is to make tools you love, with the features you want, and performance you can't live without.

Posted
4 minutes ago, Josh said:

It's just widget:SetSliderValue() and widget:GetSliderValue().

I honestly feel really dumb because I swear I tried that already, but I guess I was typing or doing something wrong because it works.

  • Haha 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...