MATLAB: How can i add a new drop down menu from an old one

drop down menuguimatlab guitext box

I am building a GUI in matlab with multiple drop down menu and text boxes what I want to do is when I choose a specific value that I defined a new drop down menu will be created or made visible

Best Answer

In the callback for the drop down menu (are you using what the Mathworks badly calls a "popup"?), call uicontrol to create new menu items or controls, or call set() to turn the 'Visible' property of the control to 'on' or 'off'
set(handles.pushbutton1, 'Visible', 'off'); % Hide push button