LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mike
 
Posts: n/a
Default Calculating Month To Date Revenue

I have a workbook with two sheets. Sheet 1 looks as follows:

A B
1 Date
2 MTD Revenue

Sheet 2 will have two columns of data. Column A will contain individual
dates begining with 1/1/2006 in row 1 and ending with 12/31/2006 in Row 365.
In column B will be the daily revenue for each of those days.

In cell B1 on Sheet 1 I want the user to be able to enter a date and in cell
B2 I want a formula that will calculate the month to date revenue up to that
date. In somes cases the formula will be adding just one row and in others it
may be adding up to 31 rows.

In an answer to a previous post of this question I was given the following
formula:

=SUMIF(Sheet2!A:A,"<="&Sheet1!B1,Sheet2!B:B)

This formula doesn't work because it returns the toatl revenue since the
beginning of the year. Let me clarify if I can.

Assume Sheet 2 looks as follows:


A B
1 1/1/06 100
2 1/10/06 200
3 1/31/06 300
4 2/2/06 20
5 2/12/06 30
6 2/22/06 55

If cell B1 in Sheet 1 is populated as follows, then these are the results I
would expect to see:

Value of B1 Result
1/1/06 100
1/2/06 100
1/10/06 300
1/17/06 300
1/31/06 600
2/1/06 0
2/15/06 50
2/28/06 105

Any thoughts? I tried the MONTH funtion but I could not get it to work.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Formula to get 1st,2nd,3rd,4th,5th Sundays from month end date. mikeburg Excel Discussion (Misc queries) 5 September 29th 05 06:59 PM
How do I break a date range by month? HeatherDawn Excel Discussion (Misc queries) 2 September 1st 05 07:31 PM
i want to display the month from a date into another cell weazal5 Excel Worksheet Functions 1 April 26th 05 08:51 AM
How do I copy only the month from a date CCW Excel Worksheet Functions 2 April 15th 05 02:26 AM
Return the end of month date from a date Steve F. Excel Worksheet Functions 3 October 28th 04 06:17 PM


All times are GMT +1. The time now is 05:12 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"