This scenario is part of
Example 11: Window with Separate Search Dialog. To get a dialog
that can act as a permanent toolbar to assist in queries in a
||Create a new subclass of the Dialog Box class, rename it to
||In the Controls Group, insert a text box with prompt:
Destination, and set the Related Column property to:
A lookup button appears that
calls a lookup window for Tours.
||Insert a text box with prompt: Customer Name, and set the
Related Column property to:
||Rename the OK and Cancel buttons to "Find" and "Close"
respectively, and reposition them if required.
||Open the Object Activator for the Action property of the Find
button, remove the dialog-ok() action, and compose this method call
In this script,
"myReservations" is a user-defined property of the dialog class. It
represents a window object, not a string. Here are the steps for
writing this script:
||Make sure the FindExistingReservations dialog is selected in
the Object Browser tree view (top-left).
||In the Methods pane, click the Properties tab page, and click
||In the New Property dialog, specify Name = myReservations, Type
= Reservations, accept 1 as the Argument Position, and click
Because you specified a new
property with an object-like type, a new node for myReservations is
added to the Object Browser pane.
||Back in the Object Activator, click the myReservations object
in the Object Browser, then select the QueryDefine() method, and
then click Add.
||In the Object Browser pane, select the
"myReservations.query.destination" column object, and then click
||Select the empty parameter node of the newly added method call,
select the "Variables.Text_Box_1" object, and then click Set.
||Follow the same steps to produce the method call passing the
||Finally, add the "myReservations.QueryExecute() call and click
OK to exit the Object Activator.
Continue with Reservations Window.