+ Reply to Thread
Results 1 to 5 of 5

In nned of a formula that would keep my answer within the same year

  1. #1
    Registered User
    Join Date
    11-13-2013
    Location
    Portland, Oregon
    MS-Off Ver
    Excel 2010
    Posts
    3

    In nned of a formula that would keep my answer within the same year

    I have a particular situation in which I would like to create a formula that will resolve to a date within a given year that I am working within without leaving that same year.

    For example, I need to create a formula that moves around within the current year 2013 WITHOUT moving my calculation to the following year of 2014.

    When I attempt to create a calculation that calls for: October 2013 to 'add' three months to the formula, I would like that calculation to essentially provide me with a "wrap around" effect and provide me with the answer of "January 2013" (placed in column: "A1" on the spreadsheet) instead of the logical anwer of "January 2014". Normally, I could create a formula such as: EDATE (A1,-9) which would then give me: "January 2013", which is what I want. The problem with this formula is that not every month in 2013 needs to result to a "wrap around" effect due to the fact that it's potential answer will reside within the year 2013. I am just having problems creating this effect for the months of July going forward within 2013. Does this make sense??

    I would like to create a function that would produce an asterisk "*" within year 2013 only, without adding my formula and moving my asterisk "*" to year 2014.

    I have attempted to resolve using everything from: EDATE, DATE, IF & EDATE combinations with no resolution to my problem. It is my hope that I can handle this issue without using VBA due to the fact that other people that may use the spreadsheet are not too familiar with VB. I will use VB if I have to, it is just not my first choice and I would still need assistance with having this done in VB

    Is there any pre-set formula that I can use that would resolve this issue? Thanks in advance.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,463

    Re: In nned of a formula that would keep my answer within the same year

    Try this approach:

    =DATE(YEAR(A1),MOD(MONTH(A1)+3-1,12)+1,DAY(A1))

    The bit in red is the number of months you want to add on. Instead of DAY(A1) you could just have the number 1 if you are only interested in the resulting month.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    11-13-2013
    Location
    Portland, Oregon
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: In nned of a formula that would keep my answer within the same year

    Pete,

    That completely worked!! You are awesome!!! Thank you, thank you, thank you!

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,463

    Re: In nned of a formula that would keep my answer within the same year

    Well, that's good to hear - thanks for feeding back.

    If that takes care of your original question, please select Thread Tools from the menu above your first post and mark this thread as SOLVED.

    Also, since you are relatively new to the forum, I would like to inform you that you can directly thank those who have helped you by clicking on the small "star" icon located in the lower left corner of a post that you have found to be helpful (not just in this thread - for any post that has helped you). This also adds to the reputation of the poster (the small green bars in the poster's profile).

    Pete

    EDIT: Hey!! that was my 6,000th post

  5. #5
    Registered User
    Join Date
    11-13-2013
    Location
    Portland, Oregon
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: In nned of a formula that would keep my answer within the same year

    Congratulations to you and me then! It came at the right time for me!

+ 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. [SOLVED] Keeping a date as current year, even though formula determines previous year
    By dropanddrive03 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-28-2013, 08:31 PM
  2. Replies: 0
    Last Post: 11-23-2012, 01:27 AM
  3. Replies: 0
    Last Post: 09-12-2009, 11:07 AM
  4. Replies: 3
    Last Post: 03-12-2009, 09:54 AM
  5. formula - calculate the yearly cost each year of the 10 year contract
    By Ineedxhelp in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-14-2008, 11:23 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