Hello,
I'm working on a sheet where I'm trying to use the worksheet_change event. I'm trying to use the change event to run the code that updates Total Stock In & Out as well as Stock on Hand.
Specifically it is a Stock Control system. There are 5 columns: 1) Stock In (Orders), 2) Total Stock In, 3) Stock Out (Sales), 4) Total Stock Out, 5) Stock on Hand.
To accomplish say, stock orders IN I have tried to use a Paste Special xlAdd to add stock orders to total stock, the business rules for each columns are:
1) Stock IN and 4) Stock OUT are keyed by the user,
2) Total Stock IN and 4) Total Stock OUT need to be calculated as cumulative columns, e.g. Total Stock in (Now) = Total Stock in (Previous) + Stock In (Now) ; This is the same type of calculation for the Total Stock Out (Sales) column.
3) Stock reduced by the Amount of Sales or Stock Out,
4) Total calculated as per 2) above.
5) Stock on Hand is calculated as Total Stock IN - Total Stock Out
It seems simple enough but I'm having all sorts of unexpected results occuring with the Change event and running the code, any suggestions please?