Update query too few parmeters
My function called UpdateOrders is triggered by the OnClick event
of a List box called ListOrderID. This list box shows the orders with their orderid number.
I produce however the error too few parameters,which means that
i am not referring correctly somewhere.
Could i have some help?
Below is the function:
Public Function UpdateOrders()
Dim MyForm As Form
Set MyForm = Forms![frmCustomerOrders]
Dim strWhere As String, strCondition As String
strCondition = "OrderID=" & MyForm.ListOrderID
strWhere = " WHERE " & strCondition
strSQL = "UPDATE orders INNER JOIN (products INNER JOIN " & " [order details] ON (products.Productid = [order details].ProductID) " & "AND
(products.Productid = [order details].ProductID)) " & "ON orders.orderid = [order details].OrderID" & _
" SET " & "products.Line1 = products.branchLine1 +[order details].cartons & StrWhere"