Hi, I have an form for placing orders, it has 4 subforms on it, 3 of which apply to this.
The first subform is for the order info, its tied to the main form via VendorID, it also has OrderID
The 2nd subform is for order details, inventory given on an order, its linked to the order info subform via OrderID. It also has a ProductID.
The 3rd subform is inventory remaining for the vendor the order is being placed for. Its linked to the main form via VendorID. It also has ProductID which is common to the 2nd subform and a way to tie them together, hopefully.
What I need is when a new order is being placed the child records on the "order details" subform will auto populate to whatever product is showing on the "inventory remaining" subform.
If I add
Me.Product2 = Forms!CreateOrders!VendorInventoryLevelSubform.For m!Product
to the on click event on the new order detail subform it will populate with the first record on the "remaining inventory subform" however it uses the same record on that form for all new product given.
I tried creating a recordset between the 2 subforms with productID and another with product name but neither worked because no records exist on the first subform. I thought it might after I add items but it broke and gave debug error. The only idea doing this was to try and link them so I could use the above code "on click" event and have someone just click the new item row and it populates that would be easier then it currently is. Ultimately it would be nice to have it look like the middle subform on the picture I attached when the form opens except with a 0 in the given.
As I mentioned I attached a picture of the form and some notes on it explaining better. If you have any ideas on how I should tackle they would be appreciated.