I have three tables STOCK, RESTOCK, USED.
And one form with two subforms (FMSTOCK, SUBFMRESTOCK and SUBFMUSED). The form is based on the STOCK table, and the two subforms are based on RESTOCK, and USED.
I have a textbox in FMSTOCK called TOTAL which subtracts the total in SUBFMUSED from the total in SUBFMRESTOCK, to show me how many of the item I have left.
This all works fine.
Unfortunately I cannot work out how to get the number shown in the textbox TOTAL to replace the amount of stock shown in the STOCK table (need to do this to make it easy to run a reorder report) when I add records to either RESTOCK, or USED. I cannot link the textbox TOTAL direct using the control source, as the control source is set to subtract the totals from the textbox’s in the two subforms ( ie =[subrestock]-[subtaken] )
I have tried to use an update query, which is run through a macro via the onchange, and on update options in the properties of the TOTAL textbox on the FMSTOCK form. Nothing happens. I have tried to add a textbox which uses the field AMOUNT from the STOCK table as the control source, which would then update to the TOTAL textbox when the TOTAL textbox changes. Again nothing happens.
Please help.