MATLAB Creating Graphical User Interfaces

(Barry) #1
Modal Dialog Box in GUIDE

4 In the Layout Editor, right-click the static text, Do you want to create a
question dialog?, and select Property Inspector.


5 Change the String property value to Are you sure you want to close?


6 In the Layout Editor select File > Save.


7 In the Save As dialog box, in the File name field, type modaldlg.fig.


Set Up a UI with a Close Button


To set up a separate UI with a Close button:


1 In the GUIDE Layout Editor, select File > New.


2 In the GUIDE Quick Start dialog box, select Blank GUI (Default). Then, click OK.


3 From the component palette on the left, drag a push button into the layout area.


4 Right-click the push button and select Property Inspector.


5 Change the String property value to Close.


6 Change the Tag property value to close_pushbutton.


7 From the File menu, select Save.


8 In Save As dialog box, in the File name field, type closedlg.fig. Then, click
Save.

Free download pdf