Problem with 1 Query with Criteria feeding another query

R

Robbro

I have one query summarizing data that then feeds another query that begins
to work on it. I made a form to filter the very first query in my process by
date, right now I have 2 items begdate and enddate. I added the date field
of the underlying table to my first query and in design view on "Total"
selected "where" and in the criteria section added
"<[Forms]![frmFilterForm]![enddate] And >[Forms]![frmFilterForm]![startdate]"
Opening this Query works fine and results in the correct info being shown.

When I try to open any query which is based on the first one above I get an
error about Access not recognizing [Forms]![frmFilterForm]![enddate] as a
valid field, name or expression?
 
R

Robbro

Nevermind, found it. I did search the forums before posting but not
thoroughly enough I guess.
 
J

Jeff Boyce

Others may face what you have. If you post the solution you found, others
could benefit when they search.

Regards

Jeff Boyce
Microsoft Access MVP

--
Disclaimer: This author may have received products and services mentioned
in this post. Mention and/or description of a product or service herein
does not constitute endorsement thereof.

Any code or pseudocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.

Robbro said:
Nevermind, found it. I did search the forums before posting but not
thoroughly enough I guess.


Robbro said:
I have one query summarizing data that then feeds another query that
begins
to work on it. I made a form to filter the very first query in my
process by
date, right now I have 2 items begdate and enddate. I added the date
field
of the underlying table to my first query and in design view on "Total"
selected "where" and in the criteria section added
"<[Forms]![frmFilterForm]![enddate] And
[Forms]![frmFilterForm]![startdate]"
Opening this Query works fine and results in the correct info being
shown.

When I try to open any query which is based on the first one above I get
an
error about Access not recognizing [Forms]![frmFilterForm]![enddate] as a
valid field, name or expression?
 
R

Robbro

http://allenbrowne.com/ser-67.html#Param

I had to declare my form fields as parameters in my crosstab query.
Not sure what that means but it works :)

Jeff Boyce said:
Others may face what you have. If you post the solution you found, others
could benefit when they search.

Regards

Jeff Boyce
Microsoft Access MVP

--
Disclaimer: This author may have received products and services mentioned
in this post. Mention and/or description of a product or service herein
does not constitute endorsement thereof.

Any code or pseudocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.

Robbro said:
Nevermind, found it. I did search the forums before posting but not
thoroughly enough I guess.


Robbro said:
I have one query summarizing data that then feeds another query that
begins
to work on it. I made a form to filter the very first query in my
process by
date, right now I have 2 items begdate and enddate. I added the date
field
of the underlying table to my first query and in design view on "Total"
selected "where" and in the criteria section added
"<[Forms]![frmFilterForm]![enddate] And
[Forms]![frmFilterForm]![startdate]"
Opening this Query works fine and results in the correct info being
shown.

When I try to open any query which is based on the first one above I get
an
error about Access not recognizing [Forms]![frmFilterForm]![enddate] as a
valid field, name or expression?


.
 

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

Top