Continuous form with Combo for searching Multiple Fields (1 Viewer)

Moore71

DEVELOPER
Local time
Today, 10:12
Joined
Jul 14, 2012
Messages
158
Hi,
I have a simple inventory which has an order form (continuous form)
I want to be able to scan barcode from 2 or 3 fields in a table like, an Item can have UPC or JAM or EAN code. So when any of the code is scan, the same Item show pop up.
Below are the tables with their fields:

tbItem= ID, ItemName, ItemCode1, ItemCode2, ItemCode3
tbOrder= ID, QtyOrder, DateOrder, ItemID

Please I need the easy way out using combo box or textbox
 

Minty

AWF VIP
Local time
Today, 10:12
Joined
Jul 26, 2013
Messages
10,353
You may need to think about your data design - what happens when a 4th barcode type arrives ? You will have to start over again.

You would be better having another table with the ItemID and the barcode, perhaps with the barcode type listed for clarity.
Then simply lookup the matching barcode from the one table and it will return the ItemID. That way you can have 1,2,3,10 barcodes for the same Item without worrying about redesigning everything.

Also I wouldn't call all your Primary Key fields ID as you'll get confused as to which ID you are referring to. Make it a meaningful name eg. ItemID, OrderID
 

Moore71

DEVELOPER
Local time
Today, 10:12
Joined
Jul 14, 2012
Messages
158
Ok, please show me a simple way of how to go about this

Give me relationship and explain how to call those fields

Thank you for your concerns
 

Minty

AWF VIP
Local time
Today, 10:12
Joined
Jul 26, 2013
Messages
10,353
Here is a simple layout.


Populate it with some test data. Make some simple forms and see if you can look up the barcodes.
If you get stuck then we can help your further.
 

Attachments

  • BarcodesLayout.JPG
    BarcodesLayout.JPG
    35.6 KB · Views: 249

Moore71

DEVELOPER
Local time
Today, 10:12
Joined
Jul 14, 2012
Messages
158
Thank you for this relationship example.
But I am still confuse a little because i am intending to use a form/subform and the subform is continuous form.
Now how do i select item using code? or query?

Please be kind enough to still show me rough example.
 

Users who are viewing this thread

Top Bottom