Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
What I am trying to do is get my excel SS to pull any dates within the
current month for payments. I would likethe cell to say something like "if cell A1 is in this month, display the date in B2, otherwise take the date from B3". I have come up with =IF(A1=DATE(YEAR(NOW()),MONTH(NOW()),),B2,B3), but I am obviously having a problem without a day entered, it always gives the date in B3. Any help would be appreciated. thx. |
#2
![]() |
|||
|
|||
![]()
One way
=IF(MONTH(A1)=MONTH(TODAY()),B2,B3) If you want to test for years as well =IF(DATE(YEAR(A1),MONTH(A1),DAY(TODAY()))=TODAY(), B2,B3) -- Regards, Peo Sjoblom "Brian" wrote in message ... What I am trying to do is get my excel SS to pull any dates within the current month for payments. I would likethe cell to say something like "if cell A1 is in this month, display the date in B2, otherwise take the date from B3". I have come up with =IF(A1=DATE(YEAR(NOW()),MONTH(NOW()),),B2,B3), but I am obviously having a problem without a day entered, it always gives the date in B3. Any help would be appreciated. thx. |
#3
![]() |
|||
|
|||
![]()
One mo
=IF(text(a1,"yyyymm")=text(TODAY(),"yyyymm"),B2,B3 ) Brian wrote: What I am trying to do is get my excel SS to pull any dates within the current month for payments. I would likethe cell to say something like "if cell A1 is in this month, display the date in B2, otherwise take the date from B3". I have come up with =IF(A1=DATE(YEAR(NOW()),MONTH(NOW()),),B2,B3), but I am obviously having a problem without a day entered, it always gives the date in B3. Any help would be appreciated. thx. -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
NETWORKDAYS - Multiple Date Selection | Excel Discussion (Misc queries) | |||
How do I break a date range by month? | Excel Discussion (Misc queries) | |||
Formula for current month minus one = Quarter number in a macro. | Excel Discussion (Misc queries) | |||
Month Year Date Format | Excel Worksheet Functions | |||
Return the end of month date from a date | Excel Worksheet Functions |