What does your query return? You do not explain how the query knows which records to return, or does it only return one row of records?
As Brian suggested, have a look at the Access help file for DLookup, it will tell you exactly how to set up this code. It also has some great examples to help...