your query is a parameter query... It's looking for two pieces of data...
What I tend to do is build my sql string in code and then pass the string into an openrecordset command...
now i know your saying to yourself that it should work fine because the query refers to a form that is open and has data in the fields that it needs... (well, that's what i said the first time i came across this error, worked for some time tring to correct it)
the only solution i was able to find was to build the sql in code and pass it to the open recordset command...
If you need help doing this, I'd be more then happy to help...
--James
junior1544@jmjpc.net
Life is change. To deny change is to deny life.
I have tried inserting the following. Still Asking for 1 Parameter. I have form open and set to a contactID. Still can't get it to work. Any suggestions.
Set rs = db.OpenRecordset("SELECT tblContacts.contactID, FROM tblContacts WHERE (((tblContacts.contactID)=[Forms]![frmContacts]![contactID]));", dbOpenDynaset)
Set rs = db.OpenRecordset("SELECT tblContacts.contactID, FROM tblContacts WHERE (((tblContacts.contactID)=" & Forms!frmContacts!contactID & ");", dbOpenDynaset)
See if that works
--James
junior1544@jmjpc.net
Life is change. To deny change is to deny life.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.