> I'm using the following parameter in a query to get records from a
> table using a sub-form:
[quoted text clipped - 7 lines]
>
> Thank you!
With a parameter you can't. By the way it will use the currently selected
record in the subform, not necessarily the "first" one. This is the same
behavior you would get if the parameter were referencing a control on the
main form right? You would get a match on that control for the current
record, not for every record in the form's RecordSource.
Sounds like you need to add the table that the subform uses to your query
and then filter on the related field in the main table by referencing a
control on the main form.

Signature
Rick Brandt, Microsoft Access MVP
Email (as appropriate) to...
RBrandt at Hunter dot com