Infinite
More left to learn.
- Local time
- Yesterday, 22:53
- Joined
- Mar 16, 2015
- Messages
- 402
Hello!
That is what I want. In the WHERE that is going to a Report that has Text boxes that get there info from Check boxes. Anyways, what I need is that to work. When I try to Run/View it, I get the error
"The Microsoft Access database engine does not recognize "[Forms]![frmreports]![Text22]" as a valid field name"
I can just out "2012" in the criteria and it works showing only "2012" but otherwise it doesnt. I am not sure if this is even possible (seems like that because I can with a normal query, and by hand) any help would Greatly be appreciated! Thanks!
Code:
TRANSFORM Sum(qryItemsSold.Quantity) AS SumOfQuantity
SELECT tblItems.Model
FROM tblItems INNER JOIN qryItemsSold ON tblItems.ModelID = qryItemsSold.ModelID
WHERE (((Format([Date],"yyyy"))=[Forms]![frmreports]![Text22] Or (Format([Date],"yyyy"))=[Forms]![frmreports]![Text24] Or (Format([Date],"yyyy"))=[Forms]![frmreports]![Text26] Or (Format([Date],"yyyy"))=[Forms]![frmreports]![Text28]))
GROUP BY tblItems.Model
PIVOT Format([Date],"yyyy");
That is what I want. In the WHERE that is going to a Report that has Text boxes that get there info from Check boxes. Anyways, what I need is that to work. When I try to Run/View it, I get the error
"The Microsoft Access database engine does not recognize "[Forms]![frmreports]![Text22]" as a valid field name"
I can just out "2012" in the criteria and it works showing only "2012" but otherwise it doesnt. I am not sure if this is even possible (seems like that because I can with a normal query, and by hand) any help would Greatly be appreciated! Thanks!