this works fine except it counts all the records in the table and not just the set of records which were selected in the query, when I change "tblQuestions" to the name of my query "qryQuestions" I get nothing. How can I change this to count only those records selected from the query?
You're wanting to limit the count to the number of records presented where? In the currently open form?
But the form is based on a query - not a table.
would surely be what you need.