Prev: Advanced Stop ODEs
Next: Convert to PDF via MATLAB
From: Walter Roberson on 23 Jul 2010 12:28 Adam Parry wrote: > Ok. I assume I can sort that bit out by taking L-E and adding that on to > b or something. But the trouble I am having is this storing of the > original value that you are talking about. i am reasonably new to matlab > and have pretty much bundled myself through so far. This GUI function > business is really above my head. Any advice would be much apreciated. Outline: X = 12345; hslider1 = uicontrol('Style','slider', 'Value', X, 'UserData', X, 'Callback', @slider1_callback); function slider1_callback(hObject, evt, handles) currentval = get(hObject, 'Value'); oldval = get(hObject, 'UserData'); ...... oldval = currentval; set(hObject, 'Value', oldval, 'UserData', oldval);l end |