There may me multiple errors
But one that I can spot straight away is quite a common error I have seen repeated in questions in the Database section:
In your code, where you have the subquery clause,
Code:
& " WHERE DateRecvd Between frmprtaudit.dtpicker1" _
& " And frmprtaudit.dtpicker2)", dbOpenDynaset)
How does the DB engine know what "frmprtaudit.dtpicker1" or "frmprtaudit.dtpicker2" are?
You will need to place the correct type of value in here at the very least. I recommend
Code:
& " WHERE DateRecvd Between #" & frmprtaudit.dtpicker1 _
& "# And #" & frmprtaudit.dtpicker2 & "#)", dbOpenDynaset)
If you ever have this sort of error, just debug the line by first placing your sql query into a string, print the string, then attempt to run the query. You would have noticed the problem yourself if you had done this...
Cheers