Input and Output GUI using Guide
Show older comments
Hello everyone,
I created a GUI to take around 12 inputs from the user then I took those inputs and stored them in variables.
Some of those variables created are based on the user's selection of a radiobutton, for example if a user selects radiobutton x I store the value 3 in a variable called m.
Example: % --- Executes on button press in radiobutton16.
function radiobutton16_Callback(hObject, eventdata, handles)
m=0
Now I would like to write a code to process those variables and perform operations on them. However every time I do that I get errors like this one:
Undefined function or variable 'a0'.
Error in Input_GUI_2>Input_GUI_2_OpeningFcn (line 59)
z=a0-b0
Error in gui_mainfcn (line 220)
feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
Error in Input_GUI_2 (line 42)
gui_mainfcn(gui_State, varargin{:});
Even though a0 is a variable created later on in the code: a0=get(handles.edit13,'string')
Can anybody please tell me what to do now?
Thanks a lot in advance.
Accepted Answer
More Answers (0)
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!