Refer to a control in a subform

  • Thread starter Thread starter Ivor Williams
  • Start date Start date
I

Ivor Williams

I have a form frmSite with a subform sfrSiteMaterial. On the subform is a
textbox txtProjNo.

I want to generate a report which uses as a datasource a query. In the query
is a field ProjNo. I want to set the criteria in this field to refer to the
textbox in the subform. Can someone please tell me the proper syntax for
doing so?

Thanks,
Ivor
 
Try:
[Forms].[frmSite].[sfrSiteMaterial].[Form].[txtProjNo]

Explanation:
Referring to Controls on a Subform
at:
http://allenbrowne.com/casu-04.html

If it still doesn't work, it is possible that the Name of the subform
control is not the same as the name of the form loaded into it (i.e. its
SourceObject.)
 
Back
Top