Hello everyone.......
I am very much in the process of learning both Access and associated programming. (Albeit I learn both by doing and not in any courses or schooling)
I have already built a large database and now need some assistance with the code for a particular requirement:
Background:
The database is used to monitor and control customer details.
Part of the database is specifically for asset tracking and I have already used basic code to allow inputs to be subtracted or added to the specified record thus allowing a live tracking of the particular asset "Stillages".
I have 2 tables:
- table 1 "CustomerT" holds all information relevant to each customer including the current quantity of stillages "StillageQty"
- table 2 "StillageLocationT" holds the location of our 4 main storage areas and the quantity of stillages at each location "Stillages"
LocationID Location Stillages 1 profine UK 2000 2 Bentons 2000 3 Foilit 245 4 HL Plastics 200
What I need now is to add code to my existing code that on updating any customer StillageQty within table CustomerT it also adds or subtracts from record 1 in table StillageLocationT
The code I am using to amend the customer StillageQty is bound to a form and its buttons as follows (when a number is typed into "StillageQtyText" and the "Delivered" button is clicked):
Private Sub DeliveredButton_Click()
Me.StillageQty = Me.StillageQty + Me.StillageQtyText
Me.StillageQtyText = ""
Me.StillageQtyText.SetFocus
End Sub
I know there will be a really simply line to or two to add in the above to not only update the StillageQty but also of record 1 of table StillageLocationT.....I just cannot find this simple solution!!!
I would appreciate any assistance at all.....thanks!