S1LV3RF0X87
Registered User.
- Local time
- Today, 12:33
- Joined
- Jul 7, 2017
- Messages
- 26
Hey all, I am having issues trying to pull the make & model of a phone from another table.
I have the following code that when a user inputs the IMEI of a device it goes away and pulls the Make ID(CatergoryID) and the Model ID(ItemID) and then populates those values on my form.
The issue that I have is I have a table for all the makes then another table for all the different devices for that make so in my stock table i just record the ID numbers so the code is working correctly for the most part.
I need to amend it so when it finds the MakeID(CatergoryID) it then looks up that value in the Catergories table to then return the name of that make & vice versa for the the model(ItemsID).
Tables are called;
-Catergories
-Items
-Stock
If anyone can help me out that would great.
I have the following code that when a user inputs the IMEI of a device it goes away and pulls the Make ID(CatergoryID) and the Model ID(ItemID) and then populates those values on my form.
Code:
Private Sub Command181_Click()
myitem = IMEI
[CatergoryID] = DLookup("[CatergoryID]", "[Stock]", "[ID]= " & myitem)
[ItemID] = DLookup("[ItemID]", "[Stock]", "[ID]= " & myitem)
Me.Requery
End Sub
The issue that I have is I have a table for all the makes then another table for all the different devices for that make so in my stock table i just record the ID numbers so the code is working correctly for the most part.
I need to amend it so when it finds the MakeID(CatergoryID) it then looks up that value in the Catergories table to then return the name of that make & vice versa for the the model(ItemsID).
Tables are called;
-Catergories
-Items
-Stock
If anyone can help me out that would great.