Can you explain, in terms of your database, what actions will increase Stock levels and which will decrease them?
There are two basic approaches to what you want, a script can update a number field in products or a calculation field can compute current stock on hand from data in the related tables. The simple number field makes for fast reports but risks a much greater chance of storing an incorrect stock level. A list or table view of many Products records may update slowly if you use a calculation field to show the stock levels but the calculation field will always show a total consistent with the entries in the related table that affect the calculated total.
Thanks Phil - I believe now that this has more or less been sorted from my other post fixing my script.
However, in answer to your question - To add stock, the user need simply add the amount to add to a product, on the product record in a list view. A script is then initiated to add this number to the physical stock field.
To use stock, as it were, the user clicks on a button called confirm, once an order has been placed, on the order layout, This script loops through the invoice items records in the portal and takes off the relevant quantities from the physical stock fields for each product. If the amount will go to 0 or less, then a warning comes up. I will need to add a back order function to the database but will do that this week...