Adding textbox to form based on select query

analyst1

Registered User.
Local time
Today, 08:59
Joined
Nov 9, 2009
Messages
24
I am using a union query to show the # of absences of staff, and if they are classified as "stage 1" they are to be given a letter stating that they are in "stage 1". Now the date in which the letter is delivered is to be inputted. That's where i'm stuck.

How would I go about adding a input field into a select query?
 
Add a parameter statement in the criteria for the appropriate field:

[Please Provide Letter Date:]
 
The Date Delivered field is currently empty, and I want the user to enter in the date of delivery via the txtdelivered text box. I entered in the parameter as you suggested but I'm receiving the following error:

"Microsoft Jet Database engine does not recognize 'Forms![Stage]!txtdelivered as a valid field name or expression"

any suggestions?
 
You did not indicate that you even had a form. The statement that I provided was to be placed directly in your query.

Now that you indicate that you have a form and a field on that form where the user is to enter the date, try this:

Open your query in design mode. Place the cursor in the criteria row of the date field you need to use for filtering. Right click and select the "Built .." option. You will be presented with a dialog box where you can double click on the "Forms" option in the left list box. Then double click on the "Loaded forms" option (this assumes you also have your form open in design mode). If you form is not open you can use the "All Forms" option. Then locate your form by name and click on it. A list of the controls on that form will be displayed. Locate and select the text box control where the user will be providing the date and click on it. Then click on the "Paste" option. Now click the "OK" button and the statement needed to reference the text box control for the criteria for the query will be placed in the query. Give it a try.
 
Didn't work, as I'm still receiving the same problem.

Is it even possible to enter data (via a form) into a union query?
 

Users who are viewing this thread

Back
Top Bottom