Error occur when open from other gui (Error while evaluating uicontrol Callback)
Afficher commentaires plus anciens

Hi everybody. my problem is my gui calculator works fine but has error when open from other gui.i can open it but the error occur when i press the push button on the calculator. all push button show the same error.
% --- Executes on button press in pushbutton2.
function pushbutton2_Callback(hObject, eventdata, handles)
% hObject handle to pushbutton2 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
textString = get (handles.answer,'String');
textString = strcat(textString,'2');
set(handles.answer,'String',textString)
the coding for all push button are same except for the push button number. I'm using this coding to open the calculator from other gui.
function calculator_Callback(hObject, eventdata, handles)
% hObject handle to calculator (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
open calculator.fig;
delete(gcbf)
can anyone help me on this problem?thanks
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Loops and Conditional Statements 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!