Enter a parmeter value intermittent

CALV

Registered User.
Local time
Today, 04:47
Joined
Apr 25, 2001
Messages
74
Hi all,

I have a problem in a database I'm designing at the moment. Basically I have a form (frmMain) which is filtered (from another form). I can then go through the filtered records no problem. I made a query, and also a report based on this query. The query has all fields from the main table (same as frmMain), and I want to base the query on a field on the filtered form (fldJobRef). Now, sometimes this works fine, othertimes I get the box saying "enter a parmeter value" for Forms!frmMAIN!fldJobRef. The form frmMain is open at this time, and I can see plainly and clearly on this form a fldJobRef ! If I go into design view in the query and "build" the criteria again, it works for a short while, can anyone offer any suggestion?

Thanks

[UPDATE]
I found that if I simply open the main form without any filter at all, then the query works fine.
 
Last edited:
Access can also get confused on occasion when the ControlName and the FieldName it is bound to are the same. I preface control names with the type of control: txt for TextBox, cbo for ComboBox etc.
 
Hi,

Thanks for the reply, I'll try renaming. In the meantime I found a dirty workaround, I public'd a variable, then when I click the button to open my report, I set the variable to the field value of the jobref, then I filtered the report by that variable - not ideal but it works.
 

Users who are viewing this thread

Back
Top Bottom