Using a Form to get query parameters

  • Thread starter Thread starter DJ
  • Start date Start date
D

DJ

I'm using the following format in a query criteria box to obtain user input
of a date via a form:

Between [Forms]![daterange]![start] And [Forms]![daterange]![end]

Form name and control names are definately spelled correctly but all I get
is a standard pop up box requesting

"Enter Parameter Value" for [Forms]![daterange]![start]

Can anyone tell me why it can't recognise my form: daterange
 
I'm using the following format in a query criteria box to obtain user input
of a date via a form:
Between [Forms]![daterange]![start] And [Forms]![daterange]![end]
Form name and control names are definately spelled correctly but all I get
is a standard pop up box requesting
 "Enter Parameter Value" for [Forms]![daterange]![start]

That I don't know, but I would not use such names as daterange, start
and stop as they could possibly be reserved keywords and acces would
sometimes behave unexpectedly in this case. I would try with
daterange1, start1 and stop1 for example.

Greetings
Marco P
 
DJ said:
I'm using the following format in a query criteria box to obtain user
input of a date via a form:

Between [Forms]![daterange]![start] And [Forms]![daterange]![end]

Form name and control names are definately spelled correctly but all
I get is a standard pop up box requesting

"Enter Parameter Value" for [Forms]![daterange]![start]

Can anyone tell me why it can't recognise my form: daterange

The form IS open when you run the query right?

Try inserting the form reference using the expression builder to see if it
agrees with what you entered.
 
Thanks for suggestions. I just assumed that my form would be opened for me
which was wrong. I've opened it before the query and now it works. Thanks

Rick Brandt said:
DJ said:
I'm using the following format in a query criteria box to obtain user
input of a date via a form:

Between [Forms]![daterange]![start] And [Forms]![daterange]![end]

Form name and control names are definately spelled correctly but all
I get is a standard pop up box requesting

"Enter Parameter Value" for [Forms]![daterange]![start]

Can anyone tell me why it can't recognise my form: daterange

The form IS open when you run the query right?

Try inserting the form reference using the expression builder to see if it
agrees with what you entered.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top