G
graeme34 via AccessMonster.com
Hi I am trying to open a recordset based on an embedded SQL query but when
the code gets to setting the recordset, it is throwing an error out.
strSQL = "SELECT * " _
& "FROM tblSalesOrderLine " _
& "WHERE SalesOrderLine = " & lngOrderNum _
& " AND FullyReceived = False;"
Set rsOrdLine = CurrentDb.OpenRecordset(strSQL, dbOpenDynaset)
I have tyoed the query into the SQL builder and it worked fine there, but
when opening it from the code it is saying it is expecting 1 parameter.
Anybody know why??
the code gets to setting the recordset, it is throwing an error out.
strSQL = "SELECT * " _
& "FROM tblSalesOrderLine " _
& "WHERE SalesOrderLine = " & lngOrderNum _
& " AND FullyReceived = False;"
Set rsOrdLine = CurrentDb.OpenRecordset(strSQL, dbOpenDynaset)
I have tyoed the query into the SQL builder and it worked fine there, but
when opening it from the code it is saying it is expecting 1 parameter.
Anybody know why??