User`s guide
9 Managing and Sh aring Application Data in GUIDE
Example — Manipulating a Modal Dialog Box for
User Input
• “View and Run the changeme GUI” on page 9-23
• “Invoking the Text Change Dialog Box” on page 9-24
• “Managing the Text C hange Dialog” on page 9-25
• “Protecting and Positioning the Text C hange Dialog” on page 9-26
• “I nitializing Text in the Text C hange Dialo g B ox” on page 9-28
• “Canceling the Text Change Dialog Box” on page 9-28
• “Applying the Text Chan ge” on page 9-29
• “Closing the Main GUI” on page 9-29
This example illustrates how to do the common tasks involved in making
multiple GU Is work together. It explains how to position a second GUI
relative to the main GUI and demonstrates how data is passed to a modal
dialog box i nvo ked from a G U IDE GUI. The dialog box displays text data in
an e dit field. Changes that you make to the edit field are pass ed back to the
main GUI. The main GUI uses this data in various ways. You can update
the appearance of one o f the components of the m ain GUI by changing the
data in the modal dialog box.
The main GUI, called
changeme_main, contains one button and a static
text field giving instructions. When you click the button, the modal
changeme_dialog dialog box opens and the button’s current string appears
in an editable text field that you can then change.
If you click OK, the value of the text field is returned to the main GUI, which
sets the string property of the button to the value you entered. The m ain GUI
and its modal dialog box are sho wn in the following figure.
9-22