Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 136
  • Last Modified:

iF STATEMENT FORMULA

I love your new website look, congrats.  I am looking for an if formula for the table attached.  All I want is an if statement to subtract the previous month from the current month etc
the .
For example:

In beginning month of August  you will subtract
0 minus August number

In September formula will be

September number minus August

and so on...

Thanks and I will also take any advice or comments.
expertsexch.xlsx
0
Kdankwah
Asked:
Kdankwah
2 Solutions
 
Gerwin Jansen, EE MVETopic Advisor Commented:
Can you attach/show an example that shows what the required output is? Excel document?
0
 
KdankwahAuthor Commented:
The output will be like this.

Output:            
August      
      
MTD                   YTD
0                  2000
            
Sept       
      
MTD                    YTD
1000            3000
            
October      
      
MTD                   YTD
2000            5000
0
 
Glenn RayExcel VBA DeveloperCommented:
1) Where are these totals to be displayed/inserted into this workbook?  On a separate sheet?  In the same sheet (Sheet1)?

2) Are these example totals derived from the example data?  If so, they do not correspond.

3) There are two years of data shown here (2014, 2015).  How do they relate to your requirement?

IMO, this will be more involved than an IF statement.

-Glenn
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
SteveCommented:
Is the attached something like what you would like?

If not, could you post the workbook with the first few numbers pre-filled based on expected results.

Ta
Steve.
U--expertsexch.xlsx
0
 
Rob HensonIT & Database AssistantCommented:
The suggestion below won't work for the sample data posted because it doesn't start at zero.

Assuming MTD in column A and YTD in column B and no other numerical values in column A, the value for the current MTD would be the YTD less sum of previous MTD values. So lets assume, your October values are in row 15, the following will give the MTD for October:

=B15-SUM($A$1:A14)   {note the $ in $A$1}

Copy this down each time you need a new MTD value for the given YTD.

Thanks
Rob H
0
 
Rob HensonIT & Database AssistantCommented:
OK, now looked at attached file. My suggestion was based on data looking like the sample above, I now realise that was how the output was expected. How does the data in the attached file relate to the sample given above?

Thanks
Rob H
0
 
KdankwahAuthor Commented:
I thank both Steve and Rob for your wonderful answers.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now