GUI Error Message in the use of a push button and it is NOT the addition of 'guidata(hObject, handles);' that is missing
Afficher commentaires plus anciens
These are all of the input values for my GUI which are being converted into numbers.
rmin=str2num(get(handles.inputrmin,'String'));
thetamin=str2num(get(handles.inputthetamin,'String'));
thetamax=str2num(get(handles.inputthetamax,'String'));
BOC=str2num(get(handles.inputBOC,'String'));
OC=str2num(get(handles.inputOC,'String'));
m=str2num(get(handles.inputm,'String'));
rmax=str2num(get(handles.inputrmax,'String'));
A function is then used which calculates outputs below
opt_a, opt_b, Fmin/1000, opt_phi
These are then converted back to strings
a1=num2str(opt_a);
b1=num2str(opt_b);
Fmin1=num2str(Fmin/1000);
phi1=num2str(opt_phi);
phi1D=rad2deg(phi1);
set(handles.outputopt_a,'String',a1);
set(handles.outputopt_b,'String',b1);
set(handles.outputOptimum_Force_KN,'String',Fmin1);
set(handles.outputopt_phi,'String',phi1D);
guidata(hObject, handles);
I am getting the following error message
??? Reference to non-existent field 'outputopt_a'.
Error in ==> GUI>calculate_Callback at 371
set(handles.outputopt_a,'String',a1);
I have checked the GUI static text box which is to recieve the output and the tag is 'outputopt_a' so there is no difference here. Any idea where i have gone wrong?
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Interactive Control and Callbacks dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!