Hi,
Everyday at work I enter the SUMIFS formula on a worksheet to calculate the total dollar amount from a Pivot-table(1). I use the below formula
The Pivot table is on the "Weekly Revenue" sheet and the Totals (formula) is on another sheet called "BacklogReview"
<colgroup><col width="82"></colgroup><tbody>
[TD="class: xl69, width: 82"]=SUMIFS('WeeklyRevenue'!E:E,'WeeklyRevenue'!D:D,">="'BacklogReview'!C32,'WeeklyRevenue'!D:D<"'BacklogReview'!C33)
and copy it down. The formula allows the totals to appear any where on the spreadsheet with dates. The value for the cell "Past" and "26 Mar" is calculated separately otherwise the values are incorrect.
I would like VB code that will work out the values for the "Past" and for the last day of the month "26 Mar" when selecting a button.
Please see below for how the values are set up on the sheet
Apologies if not very clear who ever can help me on this I would be very greatful
Many thanks
[/TD]
</tbody>
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3766;width:62pt" width="82"> </colgroup><tbody>
</tbody>
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3328;width:55pt" width="73"> </colgroup><tbody>
[TD="class: xl68, width: 73"]
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3328;width:55pt" width="73"> </colgroup><tbody>
[TD="class: xl69, width: 70"]Past
[/TD]
[TD="class: xl70, width: 73"]$7,715,447[/TD]
[TD="class: xl71"]01-Jan
[/TD]
[TD="class: xl72"]$3,375,060[/TD]
[TD="class: xl71"]08-Jan[/TD]
[TD="class: xl73"]$483,787
[/TD]
[TD="class: xl71"]15-Jan[/TD]
[TD="class: xl73"]$450,817[/TD]
[TD="class: xl71"]22-Jan[/TD]
[TD="class: xl73"]$42,926[/TD]
[TD="class: xl71"]29-Jan[/TD]
[TD="class: xl73"]$2,273,545
[/TD]
[TD="class: xl71"]05-Feb[/TD]
[TD="class: xl73"]$191,500[/TD]
[TD="class: xl71"]12-Feb[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]19-Feb[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]26-Feb[/TD]
[TD="class: xl73"]$24,039[/TD]
[TD="class: xl71"]05-Mar[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]12-Mar[/TD]
[TD="class: xl73"]$224,583[/TD]
[TD="class: xl71"]19-Mar[/TD]
[TD="class: xl73"]$143,540[/TD]
[TD="class: xl71"]26-Mar[/TD]
[TD="class: xl73"]$67,412[/TD]
</tbody>
[/TD]
[TD="class: xl70"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
</tbody>
<tbody>
</tbody>
Everyday at work I enter the SUMIFS formula on a worksheet to calculate the total dollar amount from a Pivot-table(1). I use the below formula
The Pivot table is on the "Weekly Revenue" sheet and the Totals (formula) is on another sheet called "BacklogReview"
<colgroup><col width="82"></colgroup><tbody>
[TD="class: xl69, width: 82"]=SUMIFS('WeeklyRevenue'!E:E,'WeeklyRevenue'!D:D,">="'BacklogReview'!C32,'WeeklyRevenue'!D:D<"'BacklogReview'!C33)
and copy it down. The formula allows the totals to appear any where on the spreadsheet with dates. The value for the cell "Past" and "26 Mar" is calculated separately otherwise the values are incorrect.
I would like VB code that will work out the values for the "Past" and for the last day of the month "26 Mar" when selecting a button.
Please see below for how the values are set up on the sheet
Apologies if not very clear who ever can help me on this I would be very greatful
Many thanks
[/TD]
</tbody>
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3766;width:62pt" width="82"> </colgroup><tbody>
</tbody>
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3328;width:55pt" width="73"> </colgroup><tbody>
[TD="class: xl68, width: 73"]
<colgroup><col style="mso-width-source:userset;mso-width-alt:3181;width:52pt" width="70"> <col style="mso-width-source:userset;mso-width-alt:3328;width:55pt" width="73"> </colgroup><tbody>
[TD="class: xl69, width: 70"]Past
[/TD]
[TD="class: xl70, width: 73"]$7,715,447[/TD]
[TD="class: xl71"]01-Jan
[/TD]
[TD="class: xl72"]$3,375,060[/TD]
[TD="class: xl71"]08-Jan[/TD]
[TD="class: xl73"]$483,787
[/TD]
[TD="class: xl71"]15-Jan[/TD]
[TD="class: xl73"]$450,817[/TD]
[TD="class: xl71"]22-Jan[/TD]
[TD="class: xl73"]$42,926[/TD]
[TD="class: xl71"]29-Jan[/TD]
[TD="class: xl73"]$2,273,545
[/TD]
[TD="class: xl71"]05-Feb[/TD]
[TD="class: xl73"]$191,500[/TD]
[TD="class: xl71"]12-Feb[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]19-Feb[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]26-Feb[/TD]
[TD="class: xl73"]$24,039[/TD]
[TD="class: xl71"]05-Mar[/TD]
[TD="class: xl73"]$0[/TD]
[TD="class: xl71"]12-Mar[/TD]
[TD="class: xl73"]$224,583[/TD]
[TD="class: xl71"]19-Mar[/TD]
[TD="class: xl73"]$143,540[/TD]
[TD="class: xl71"]26-Mar[/TD]
[TD="class: xl73"]$67,412[/TD]
</tbody>
[TD="class: xl70"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
[TD="class: xl69"][/TD]
[TD="class: xl71"][/TD]
</tbody>
<tbody>
</tbody>