How to make invisible popupmenu?

3 Ansichten (letzte 30 Tage)
mete polat
mete polat am 23 Dez. 2015
Kommentiert: mete polat am 23 Dez. 2015
i have 4 popupmenu and when i select a value from first one, according to choise except one of them will be visible and the others will be invisible. For example, from first popupmenu i select popupmenu2, then i want just popupmenu2 will be visible and the others will be invisible. Thank you.

Akzeptierte Antwort

Walter Roberson
Walter Roberson am 23 Dez. 2015
function YourGUI_popup1_callback(hObject, event, handles)
choice = get(hObject, 'Value');
popups = [handles.popup2, handles.popup3, handles.popup4];
set(popups, 'Visible', 'off');
set(popups(choice), 'Visible', 'on');
  3 Kommentare
Walter Roberson
Walter Roberson am 23 Dez. 2015
Your String for your popup1 should be a cell array of three entries, the first being the wording for activating popup2, the second for activating popup3, the third for activating popup4. Based upon your explanation I can tell you have an extra first entry before those. If I am correct then you need to indicate what you want to happen when the first entry of popup1 is chosen.
mete polat
mete polat am 23 Dez. 2015
Thank you Walter Roberson it s working anymore.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu App Building finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by