+ Reply to Thread
Results 1 to 11 of 11

Help with dates

Hybrid View

  1. #1
    Registered User
    Join Date
    08-13-2012
    Location
    Brazil
    MS-Off Ver
    Excel 2010
    Posts
    19

    Help with dates

    Hello everybody.

    I need a help related to formulas with dates.

    I have a start date (10/02/2014) and an end date (30/10/2014) when compared with the date "eg: Jan / 14 must show" 0 "on the worksheet, where to Feb/14 should show "1" until Oct/2014.

    Ex:

    Start date End date jan/14 fev/14 mar/14 abr/14 mai/14 jun/14 jul/14 ago/14 set/14 out/14 nov/14 dez/14 jan/15 fev/15 mar/15
    10/02/2014 30/10/2014 0 1 1 1 1 1 1 1 1 1 0 0 0 0 0
    06/12/2013 30/05/2014 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0
    02/10/2013 30/03/2014 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0

    Thanks.
    Last edited by hbender; 02-24-2015 at 02:54 PM.

  2. #2
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,941

    Re: Help with dates

    will you pls attach sample excel file
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  3. #3
    Registered User
    Join Date
    08-13-2012
    Location
    Brazil
    MS-Off Ver
    Excel 2010
    Posts
    19

    Re: Help with dates

    ops sorry.
    Attached Files Attached Files

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Help with dates

    Perhaps something like this...

    =IF(and($A2>=A$1,$B2<=A3),0,1)
    (untested)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Help with dates

    this, copied down and across, gives you what you have...
    =IF(AND(E$2>=$B3,E$2<=$C3),1,0)

    Check your F3 though, you say 1, but i think it should be 0?

  6. #6
    Registered User
    Join Date
    08-13-2012
    Location
    Brazil
    MS-Off Ver
    Excel 2010
    Posts
    19

    Re: Help with dates

    Quote Originally Posted by FDibbins View Post
    this, copied down and across, gives you what you have...
    =IF(AND(E$2>=$B3,E$2<=$C3),1,0)

    Check your F3 though, you say 1, but i think it should be 0?
    I think that's my problem.

    the start date must count as one that month.

    start date: 10/02/2014.

    In February must show 1 and not 0

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Help with dates

    OK, try this instead...
    =IF(AND(E$2>EOMONTH($B3,-1),E$2<=$C3),1,0)

  8. #8
    Registered User
    Join Date
    08-13-2012
    Location
    Brazil
    MS-Off Ver
    Excel 2010
    Posts
    19

    Re: Help with dates

    Quote Originally Posted by FDibbins View Post
    OK, try this instead...
    =IF(AND(E$2>EOMONTH($B3,-1),E$2<=$C3),1,0)
    Thanks FDibbins....perfect.

  9. #9
    Forum Expert
    Join Date
    12-11-2011
    Location
    Netherlands
    MS-Off Ver
    office 365
    Posts
    3,658

    Re: Help with dates

    =--(MEDIAN(EOMONTH($B3;-1)+1;$C3;E$2)=E$2)
    Try this one
    Willem
    English is not my native language sorry for errors
    Please correct me if I'm completely wrong

  10. #10
    Registered User
    Join Date
    08-13-2012
    Location
    Brazil
    MS-Off Ver
    Excel 2010
    Posts
    19

    Re: Help with dates

    Quote Originally Posted by popipipo View Post
    =--(MEDIAN(EOMONTH($B3;-1)+1;$C3;E$2)=E$2)
    Try this one
    Thanks...Perfect

  11. #11
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Help with dates

    Happy to help, thanks for the feedback

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Check dates in range either same dates or different dates by formula
    By breadwinner in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-12-2013, 07:42 AM
  2. Replies: 6
    Last Post: 03-11-2013, 06:11 PM
  3. [SOLVED] Array of dates when tested shows no dates ......but there are dates
    By welchs101 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-29-2012, 12:45 PM
  4. [SOLVED] Highlight Group of Dates if Dates Match List of other Dates
    By martinpgibson in forum Excel General
    Replies: 5
    Last Post: 10-24-2012, 08:14 PM
  5. [SOLVED] Auto filling dates based on previously entered dates and averaging numbers if dates equal
    By grambograham in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-11-2012, 03:21 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1