#1
|
|||
|
|||
If Function Challenge involving date
I need to use a simple If function formula. The difficulty is the test argument.
Example: Column B = dates in this column could be any month and day in years 2007 through 2012, formated as 06/10/2007, 09/03/2008. Column F = amount such as 563.50, 315.95, etc. Starting with column H through M, the header of the columns with be the years, H=2007, I=2008, etc. For column H, row 10, which is for year 2007, I would like to test B10 if it is year 2007 and if yes, put the amount found in cell F10 in H10. In I10, I would like to test B10 if it is year 2008 and if yes, put the amount in cell B10 in I10. Do this for the remainder of the cells on row 10 for columns J through M, years 2009-2012 respectively. The amount in B10 will go in only one of the years from 2007 - 2012. Thanks |
#2
|
||||
|
||||
Hi
perhaps posting a small sample sheet would help?
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post |
#3
|
|||
|
|||
If Function Challenge involving date
I am attaching an example. The columns are not the same as in my original post but the idea is the same.
|
#4
|
||||
|
||||
Does the attached help?
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post |
#5
|
|||
|
|||
Absolutely!! Thanks a bunch. The only part I am not totally understanding is the part of the formula *D3, i.e. the * being the 'times or multipy' symbol like 2*3=6. It looks like the formula is saying if the argument is true, then multiply what is in cell D3, or D7 and so on. But it works just great--thanks for your time and contribution.
|
#6
|
||||
|
||||
Well, one usually uses an IF function to solve this kind of problems, which is perfectly all right.
I just decided to use another approach (YEAR($B6)=E$2) will return TRUE or FALSE (must be between parenthesis. The multiplication or any other arithmetic operator will coerce these values to 1 or 0, thus returning the value needed or a 0. To see a formula at work ,use "evaluate formula" under the formula ribbon
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post |
#7
|
|||
|
|||
Ok-I learned a lot from this exchange and a new way to solve Excel problems.
Thanks |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Change format of date when using Now function in VB code | Bondai | Excel Programming | 2 | 03-02-2012 05:09 PM |
Word Challenge | jpotter2 | Word | 3 | 03-22-2011 02:07 PM |
Today's Date Function | freschij | Excel | 3 | 02-11-2011 10:21 AM |
Automatic Date Function Corrupting Printer Output | Theodulf | Word | 0 | 05-28-2010 12:33 PM |
Date Function in word? | aligahk06 | Word | 1 | 04-21-2010 06:33 AM |