S
Shell
In Access 2000, I have a query which references a field on a form for a
criteria. The reference is written as [Forms]![frmReportTool].txtRegion]
where Region is an integer.
When the form is open and a region is selected, the query runs properly. It
recognizes the region. However, when in code I transfer to another module
and try to run the query, the reference is not converted to the value on the
form. It defaults to 0 and I get the incorrect output from the query.
When the code executes in the other module I run a docmd.openquery statement
referencing the queryname.
Does any one know why and how I can correct it?
Thanks
criteria. The reference is written as [Forms]![frmReportTool].txtRegion]
where Region is an integer.
When the form is open and a region is selected, the query runs properly. It
recognizes the region. However, when in code I transfer to another module
and try to run the query, the reference is not converted to the value on the
form. It defaults to 0 and I get the incorrect output from the query.
When the code executes in the other module I run a docmd.openquery statement
referencing the queryname.
Does any one know why and how I can correct it?
Thanks