G
Guest
On my "Orders" form I have a combo box so user can search and find any
previosly saved order. there are two columns "orderID" ans "Customer Name."
Each cusotmer has one or more orders. As long as "OrderID" is the first
column in the combo box it works fine. However, users need to search for an
order based on customer name (by typing the first few letters and getting the
customer name and then selecting one of the orderId's) I put the
"customername" in the first coulmn of the comboBox and orderID in the
second. In the "afterUpdate" event I changed the "rs.FindFirst
"[CustomerName]" line to "rs.FindFirst "[OrderID] = ' " &
Me![comboBox].column(2) & " ' ". I had to do this because there are multiple
orders per cusotmer. But I am getting "run-time error date type mismatch" I
also tried "[OrderID] = ' " & Str(Nz(Me![ComboBox], 0))
previosly saved order. there are two columns "orderID" ans "Customer Name."
Each cusotmer has one or more orders. As long as "OrderID" is the first
column in the combo box it works fine. However, users need to search for an
order based on customer name (by typing the first few letters and getting the
customer name and then selecting one of the orderId's) I put the
"customername" in the first coulmn of the comboBox and orderID in the
second. In the "afterUpdate" event I changed the "rs.FindFirst
"[CustomerName]" line to "rs.FindFirst "[OrderID] = ' " &
Me![comboBox].column(2) & " ' ". I had to do this because there are multiple
orders per cusotmer. But I am getting "run-time error date type mismatch" I
also tried "[OrderID] = ' " & Str(Nz(Me![ComboBox], 0))