I am having trouble getting the results of a query to be displayed in a textbox in a report. I was able to get the results from the following query using Dlookup
SELECT Count(*) AS NumberOfPics
FROM tblOldAbes
WHERE ((([tblOldAbes].[Day])="Monday") And (([tblOldAbes].[Time])="12") And (([tblOldAbes].[FullDate]) Between [forms].[frmDateRangeOA].[txtDateStartOA] And [forms].[frmDateRangeOA].[txtDateEndOA]));
I used =DLookUp("NumberOfPics","qryCountMondayOA12pm") and it works just fine.
The problem I am having with with my other query
SELECT [NumberOfPics]/[forms].[frmDateRangeAvgOA].[txtNumberOfSatAvgOA] AS AvgNumOfPics
FROM qryCountMondayOA12pm;
I used =Dlookup("AvgNumOfPics","qryAvgMondayOA12pmManual") and I am getting #ERROR displayed in my reports. Am I missing something simple or is it a problem with the query itself?
Any suggestions would be greatly appreciated.
Thank You
Zac Z
SELECT Count(*) AS NumberOfPics
FROM tblOldAbes
WHERE ((([tblOldAbes].[Day])="Monday") And (([tblOldAbes].[Time])="12") And (([tblOldAbes].[FullDate]) Between [forms].[frmDateRangeOA].[txtDateStartOA] And [forms].[frmDateRangeOA].[txtDateEndOA]));
I used =DLookUp("NumberOfPics","qryCountMondayOA12pm") and it works just fine.
The problem I am having with with my other query
SELECT [NumberOfPics]/[forms].[frmDateRangeAvgOA].[txtNumberOfSatAvgOA] AS AvgNumOfPics
FROM qryCountMondayOA12pm;
I used =Dlookup("AvgNumOfPics","qryAvgMondayOA12pmManual") and I am getting #ERROR displayed in my reports. Am I missing something simple or is it a problem with the query itself?
Any suggestions would be greatly appreciated.
Thank You
Zac Z