4. Select the query conditions from the form.
Although the preceding method is simple, it is not convenient for the user and difficult for the designer to control it. If it is implemented through a form, these problems can be solved.
In the following form, you can select the name of the driver to be queried in the combo box, and press the query button to view the query result.
The following describes the design steps in detail:
Create a form and press the control wizard button to add a combo box to the form. In the first dialog box
Select "I want the combo box to search for these values in a table or query" and next.
Select a table or query that provides data for the combo box. Next step.
Select the data to be displayed in the combo box. In addition to the fields to be displayed in the combo box, select the table's primary keywords. Next step.
If the primary keyword is an automatically numbered field, select "Hide primary keyword column". Next, name the combo box.
Create a query and enter the field name of the form combo box in the query field criterion. Enter "[forms] Here. [Condition query]! [Driver to query] ". For convenience, you can use the expression generator to generate this expression.
Save the query as "query by driver name ".
Return to the form and add a button. In the first dialog box of the control wizard, select "Miscellaneous/run query ". Next step.
Select the newly created query "query by driver name" and click Next.
Enter the text displayed on the button, or use an image to represent the button. Next, give the button a name to complete.
0
Run this form, as shown in the figure above this page. Select "Ma qijin" in the combo box and press "query" to view the query result.