average in a vlookup

amelieh

New Member
Joined
Aug 16, 2015
Messages
1
Hi there,

I wonder if you could help :
I have 2 tables :
table A : showing the consumption of 1 product every day. So we have the actual consumption and the forecast consumption in the same column.
Example
B2 = 14.08.2015. C2 = 96
B3 = 15.08.2015. C3 = 105
B4 = 16.08.2015. C4 = 100
B5 = 17.08.2015. C5 = 103
B6 = 18.08.2015. C6 = 98
table B : I would like to have a formula which give me the average of the consumption in the next 15 days from today's date (cell A1 in table A). so the result of the formula will change every day.

Is it possible ? If so, how ?

Thanks in advance

Amelie
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
I would use a pivot table for that kind of work.

The result is in the green cell(s).


Book1
ABCDEFGHI
1datevalueCriteria met16-8-201531-8-2015
214-8-201596 
315-8-2015105
416-8-2015100yes
517-8-2015103yesCriteria metyes
618-8-201598yes
719-8-20157yesAverage value
820-8-20158yes29,38
921-8-20159yes
1022-8-201510yes
1123-8-201511yes
1224-8-201512yes
1325-8-201513yes
1426-8-201514yes
1527-8-201515yes
1628-8-201516yes
1729-8-201517yes
1830-8-201518yes
1931-8-201519yes
201-9-201520
212-9-201521
223-9-201522
Blad10
Cell Formulas
RangeFormula
G1=TODAY()
H1=G1+15
D2=IF(AND(B2>=$G$1,B2<=$H$1),"yes","")
 
Upvote 0

Forum statistics

Threads
1,223,721
Messages
6,174,094
Members
452,542
Latest member
Bricklin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top