Retrieving data from slider
Show older comments
I've been using GUIDE and I'm having trouble getting the value from the slider.
In the generated function
function slider1_Callback(hObject, eventdata, handles)
I can get the value with
sliderValue = get(handles.slider1,'Value')
But if I try using that in a user defined function I get this error:
??? Undefined variable "handles" or
class "handles.slider1".
Did I miss something?
Accepted Answer
More Answers (1)
Categories
Find more on Interactive Control and Callbacks in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!