+ Reply to Thread
Results 1 to 6 of 6

Understanding a formula

  1. #1
    Forum Contributor
    Join Date
    11-03-2009
    Location
    Florida
    MS-Off Ver
    Excel 365
    Posts
    291

    Understanding a formula

    I built the attached vacation planner directly from the Excel Gantt Chart Template. It works great but I don't really understand how it works.
    The red cells are from a conditional format with the rule "=plan", and "plan" is a dynamic named range which refers to another named range "periodinplan".
    I think that the concept is genius but I would like to better understand how it works.

    In addition, I would like to add a formula in H1 to count the number of people on vacation on any day.

    Thank you all for your continuing help.
    Attached Files Attached Files

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,843

    Re: Understanding a formula

    To count how many people are on vacation each day, and show the counts in row 1, put this formula in H1 and copy to the right:
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    The conditional formatting use of Plan and PeriodInPlan are IMHO excessively "clever" and I don't really see how PeriodInPlan works. I would use something much simpler that is intuitive to see how it works. It simply looks at the date for that column and determines if it is between the start and end dates for that person's vacation. I have made that change in your file.

    All the effort baked in to show day-of-year in column C and row 5 seems useless to me unless you need it for some reason.
    Attached Files Attached Files
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Forum Contributor
    Join Date
    11-03-2009
    Location
    Florida
    MS-Off Ver
    Excel 365
    Posts
    291

    Re: Understanding a formula

    Thanks for the formula, works great. The day of the year is because I took the whole thing from the Excel Gantt Chart template and it used periods rather than dates. I normally keep Row 4 and Col C hidden.
    I have attached the template that I based this on. I thought it pretty clever because there are no macros or formulas used, only Named Ranges and Conditional Formatting.
    The formulas in my file are to convert dates to periods.
    Thanks
    Attached Files Attached Files

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,843

    Re: Understanding a formula

    I see. In the original, the periods are so that it can be generic. You can use it for days, weeks, or months. Once you add actual dates, you don't need the periods anymore. Here is what I would do with your file.
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    11-03-2009
    Location
    Florida
    MS-Off Ver
    Excel 365
    Posts
    291

    Re: Understanding a formula

    Thank you. I love the beauty of simplifying an overly complex problem.
    Your solution helps me to be able to use the concept in other ways (though I still don't understand how the original template works).

  6. #6
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,843

    Re: Understanding a formula

    Me neither. And honestly, it's not worth the time to figure it out. It hinges on the PeriodInPlan named formula.

+ 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. Understanding a formula
    By Tlarkin in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-16-2018, 04:37 PM
  2. Understanding this formula...
    By USNavy in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-04-2018, 04:30 PM
  3. Need Help understanding Formula.
    By BlackAtlas in forum Excel General
    Replies: 6
    Last Post: 04-06-2016, 02:59 PM
  4. [SOLVED] Understanding formula's
    By madhatter40 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-09-2013, 12:52 PM
  5. Help understanding a formula
    By excel0124 in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 04-15-2013, 02:56 PM
  6. Formula is not understanding me
    By Shainal.Sutaria in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-03-2013, 07:56 AM
  7. need help understanding a formula
    By imrainbow in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-09-2011, 01:12 AM

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