Info
Cette question est clôturée. Rouvrir pour modifier ou répondre.
How to use variable of another function with a function? switch-case. Matlab Gui
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I want to call a variable in a popupmenu from a button. I mean, popup value will only show the current status and when I press the button it will operate according to the popup menu status. Here is my code, i get "Undefined function or variable 'popupmenu4value" error when i press the button.
function pushbutton1_Callback(hObject, eventdata, handles)
switch popupmenu4value
case 'A'
%function of A
case 'B'
%function of B
function popupmenu4_Callback(hObject, eventdata, handles)
contents = get(handles.popupmenu4,'String');
popupmenu4value = contents{get(handles.popupmenu4,'Value')};
I found axesMenuToolbar in gui examples but it is written in older verison and i can't use it. what i want is exactly this "axesMenuToolbar" help gui. thanks in advance..
1 commentaire
Réponses (0)
Cette question est clôturée.
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!