I have an inventory subform using barcodes. The barcode is entered into the [Itemlookup]. Upon update [ItemUpdate] runs the following code:
Me.ItemNoLookup.SetFocus
DoCmd.RunCommand acCmdCopy
DoCmd.RunCommand acCmdCut
Me.ProductNo.SetFocus
DoCmd.RunCommand acCmdPaste
Me.QtySold.SetFocus
This takes the number from the item lookup and places it into [ItemNo] which is in the subform table below and fills in all info from the query and moves to amount sold for entry. It works great if their is only one record. It keeps changing the first record instead of going to the next record. Does anyone know how to route the code to the next record? It tried:
DoCmd.RunCommand acCmdRecordGoToNext
It shot that down.
Me.ItemNoLookup.SetFocus
DoCmd.RunCommand acCmdCopy
DoCmd.RunCommand acCmdCut
Me.ProductNo.SetFocus
DoCmd.RunCommand acCmdPaste
Me.QtySold.SetFocus
This takes the number from the item lookup and places it into [ItemNo] which is in the subform table below and fills in all info from the query and moves to amount sold for entry. It works great if their is only one record. It keeps changing the first record instead of going to the next record. Does anyone know how to route the code to the next record? It tried:
DoCmd.RunCommand acCmdRecordGoToNext
It shot that down.