+ Reply to Thread
Results 1 to 5 of 5

Adapting Existing Formulas to Changing Months

  1. #1
    Forum Contributor
    Join Date
    05-29-2017
    Location
    UK
    MS-Off Ver
    Pro Plus 2016
    Posts
    301

    Adapting Existing Formulas to Changing Months

    Hi guys, a bit tricky one here...

    There are working formulas, as excel file attached, only cant seem to find the way to adapt these formulas to new changing condition. Please see a screenshot and excel file attached for details. Would you be okay to suggest the solution?

    Thank you.

    https://www.excelforum.com/attachmen...1&d=1507330389 [EXCEL]

    2017-10-07_0147.png
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Adapting Existing Formulas to Changing Months

    Hi,

    Does the attached help.
    I've added some new numbers in row 14 to be able to compare and a monthly lookup table below. The Offset function here coupled with the return month number from the Vlookup is a more efficient way of using an expanding range of cells.
    Attached Files Attached Files
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Contributor
    Join Date
    05-29-2017
    Location
    UK
    MS-Off Ver
    Pro Plus 2016
    Posts
    301

    Re: Adapting Existing Formulas to Changing Months

    Hi Richard, thanks for looking into it.

    I'm not quite sure what was done there... you kept the original formulas (that are not valid) as well? Its linking to C13...

    D14 and E14 are same formulas to return same results?

    With this version if I now select beginning of a year as 1 March, and chose Jan from a dropdown, it will still do some calculations, when Jan is not even showing in C3:F3...

    Is there no way to do this formula, perhaps, without helper cells, so that: if a month in H12 match a month in C3:F3 then do calculation from balances in that particular column where months match (C4:F10) ?

    I'm not understanding how helper cells works either, I see if moving them around it returns N/A values, so if trying to replicate the same in original copy of a file (which contains lots more data on that sheet) I will bump into serious issue trying to make use of this suggested workaround...

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Adapting Existing Formulas to Changing Months

    The cells I added were not helper cells.
    It seemed to me that all your IF tests were redundant since you always wanted to include the C6:D6 range when the formula is in column D, the C6:E6 range when in column E, the C6:F6 range when in column F...etc. Hence I simplified your formul to show they gave the same results but without all the IFs

    If you expect the cells to return different numbers then you need to clearly explain what yuo mean by 'changing conditions'.

    So please upload a workbook and manually add ALL the results that you expect to see.

    Be sure to include at least three scenarios so that we know your end goal.

  5. #5
    Forum Contributor
    Join Date
    05-29-2017
    Location
    UK
    MS-Off Ver
    Pro Plus 2016
    Posts
    301

    Re: Adapting Existing Formulas to Changing Months

    Hi Richard,

    'changing conditions' was referring to changing names of the months (Jan, Feb, etc) after updating a date in A1.

    I've spend a great deal of time looking for a workaround, and the simplest solution I found was to simply replace Jan, Feb etc from a dropdown box with 1,2,3, etc. So whenever, say number 3 is selected, formula will take values from column 3, regardless whether that column says Mar or Aug. So it would be down to user to just quickly take a look what month number 3 stands for.

    Mission accomplished :-)

    Thanks, once again, for all of your help!

+ 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] Adapting ave formulas to changing weeks
    By vill in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 10-04-2017, 05:56 AM
  2. Update existing code to accomodate months rather than 60 days.
    By excelfriend1 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-12-2016, 04:08 AM
  3. Replies: 1
    Last Post: 02-09-2015, 06:50 PM
  4. adding new months data to an existing chart
    By sarahbeecher in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 05-20-2013, 10:55 PM
  5. Excel VB: Add Rows with formulas in an existing Table by changing a cell value
    By Charliebravo in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-04-2012, 08:59 AM
  6. Help modifying macro to wrap iferror formulas around existing formulas
    By dcgrove in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-14-2012, 02:04 PM
  7. Help adapting an existing macro.
    By paul1970 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-10-2008, 09:50 AM

Tags for this Thread

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