+ Reply to Thread
Results 1 to 7 of 7

Calculate percentages based on cell color in column

  1. #1
    Registered User
    Join Date
    12-05-2013
    Location
    Germany
    MS-Off Ver
    Excel 2007
    Posts
    4

    Exclamation Calculate percentages based on cell color in column

    Hello and thank you for your help in advance! I have a deadline to have this spreadsheet completed so please help!

    I have put together a training tracker for my organization. I have figured out (thanks to this forum site ) how to change the cell colors based on the closeness to the expiration date.
    My next goal is to have the percentages calculated and (if possible) color coated to show the percentage of people that are still valid in the separate columns E through L.

    I would like <90% to have RED background in the cell, 90-99% with yello background, and 100% with green.

    For example (please refer to the screenshot I have attached) in cell G73 I want to have the percentage of people whose "IA" training is still valid. I know you can't see the entire column but one person is expired (red) so the percentage would be around 99%. I want cell G73 to show 99% with a yellow background.

    When calculating this percentage, ensure that it only reflects those which are valid. In other words, the "EXEMPT" cells which are gray should not be included in the calculation at all. The Green cells and yellow cells are still valid and should be included in the percentage. The red cells should be the only ones that take away from the percentage.

    Thank you! let me know if this doesn't make sense.

    Josh
    Attached Images Attached Images

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Calculate percentages based on cell color in column

    Please attach a workbook - I can't tell what your data is like from a picture.
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  3. #3
    Registered User
    Join Date
    12-05-2013
    Location
    Germany
    MS-Off Ver
    Excel 2007
    Posts
    4

    Arrow Re: Calculate percentages based on cell color in column

    oops, that makes sense. sorry. here you go
    Attached Files Attached Files

  4. #4
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Calculate percentages based on cell color in column

    pretty sure you can't base a calculation on a colour applied by conditional formatting. You need to use the same criteria in a formula as your CF uses.

    So in your DL worksheet, cell G73, you can use the formula:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Copy across and apply conditional formatting to suit.

  5. #5
    Registered User
    Join Date
    12-05-2013
    Location
    Germany
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Calculate percentages based on cell color in column

    Thank you. That kind of worked but if that is the case, I need it to count the empty red boxes as incomplete too. I have typed "REQUIRED" in all those empty red boxes so is there a way to include those in the percentage calculation?
    Last edited by joker4life88; 12-09-2013 at 06:07 AM.

  6. #6
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Calculate percentages based on cell color in column

    If you want to include empty cells as needing training, then try:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    I'm sure you can see the logic now, and adapt as necessary

  7. #7
    Registered User
    Join Date
    12-05-2013
    Location
    Germany
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Calculate percentages based on cell color in column

    I see! Thank you so much. I'm barely going to make my deadline
    Good job

+ 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. Calculate two cells based on cell color
    By jaycee66 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-26-2013, 02:41 PM
  2. Calculate two cells based on cell color
    By jaycee66 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-25-2013, 12:03 PM
  3. [SOLVED] Color-format a cell which contains data in a column based on the color of another cell
    By Nit3hawK in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-27-2013, 05:25 PM
  4. Calculate total numbers based on percentages
    By FM1 in forum Excel General
    Replies: 2
    Last Post: 02-09-2009, 08:15 AM
  5. Replies: 5
    Last Post: 08-10-2005, 04:05 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