This seems to work just fine- in the data set above, this gives a total of 300 from items1,2,5.
But now, I want to allow the user the ability to enter in a number of days to add on to Date 1, and then calculate a new total. I set up an input box with a variable: v_days.
What I want my formula now to do add up all of the amounts where (Date 1 + v_days) is less than or equal to Date 2. If I entered 4 as v_days, this should give me a total of 150 (from items1,5). If I entered 10 as v_days, this should give me a total of 50 (just item 5 now works).