at work we are trying to create a simple inventory tracker in excel. The one thing we can not figure out is how to get the tracker to subtract a value
Ex. We have whats in storage Column G is the object and Column H is how much. In Column A you put what your taking and then in Column D you put how much your taking. We want D to subtract from H if A = G. Is this possible?
CodePudding user response:
you need a new column for this, if you don't want to use VBA programming.
=H4-SUMIF($A$4:$A$11;G4;$D$4:$D$11)
if you want to fill up your storage again, you can either write a minus in the outtake column or use a different column for "fill up items" then you use this formula:
=H15-SUMIF($A$4:$A$11;G15;$D$4:$D$11) SUMIF($A$4:$A$11;G15;$C$4:$C$11)