How to let user update popmenu string and add some code in popmenu?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
When I push one radiobutton the edit_text(add one selection to my popmenu string) and button(confirm adding) it will display(already does), so I need to increase my switch case or change some thing in popmenu code when user increase one popmenu opotion does it possibility? (my english is poor sorry)
ex:
before
contents = get(hObject, 'Value');
switch contents
case 1 return 1;
end
user add one
after
contents = get(hObject, 'Value');
switch contents
case 1 return 1;
case 2 return 2;
end
Does it possibility?
4 commentaires
Walter Roberson
le 16 Oct 2018
after
contents = get(hObject, 'Value');
switch contents
case 1 return 1;
case 2 return 2;
end
Why not just return what is in contents ?
Note: you cannot return anything from these kinds of callbacks; you can only store a value somewhere that other code can find the value.
Réponses (0)
Voir également
Catégories
En savoir plus sur Migrate GUIDE Apps dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!