+ Reply to Thread
Results 1 to 4 of 4

Eternally grateful if solved: % of cells with or without formatting

  1. #1
    Registered User
    Join Date
    06-07-2017
    Location
    UK
    MS-Off Ver
    Excel for Mac 15.28
    Posts
    2

    Question Eternally grateful if solved: % of cells with or without formatting

    Hi all, incredibly bored and procrastinating medical student here. I have a timetable with things I have to revise in a certain timeframe. I'm looking for a way to have cells which describe the percentage of a certain block I have completed based on the formatting of the cells. Here's an example:

    Screen Shot 2017-06-07 at 11.03.30.PNG

    As you can see, today I've completed the first two (G2:H2 and I2:J2). I have cleared the fill for these cells.

    The next one (Joint Imaging and Aspiration, K2:L2) is filled a certain colour.

    Is there a way to make a cell describe the percentage filled or unfilled?

    Thanks!

    Matt

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: Eternally grateful if solved: % of cells with or without formatting

    If you've used Condtional Formatting to set the colours then you can base a formula on the conditions that set those colours.
    If you've coloured the cells manually then you will have to use VBA to detect the colours of which I'm not an expert.
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Registered User
    Join Date
    06-07-2017
    Location
    UK
    MS-Off Ver
    Excel for Mac 15.28
    Posts
    2

    Re: Eternally grateful if solved: % of cells with or without formatting

    Quote Originally Posted by Special-K View Post
    If you've used Condtional Formatting to set the colours then you can base a formula on the conditions that set those colours.
    If you've coloured the cells manually then you will have to use VBA to detect the colours of which I'm not an expert.
    They were set manually, but I could change easily to conditional formatting. Shouldn't be an issue.

    How would I go about setting up a formula to identify conditionally formatted cells?

  4. #4
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: Eternally grateful if solved: % of cells with or without formatting

    You're not identifying cells which have a conditional format, you're using the same conditions that set the colour in the first place.

    e.g.

    In A1:A100 I want anything that contains the number 3 to be green.
    Then I want the percentage of green cells in that coloumn.

    Condtional Format =(A1=3) and format as green, condtional formatting formula then copied to other cells in that column.

    Now I want to know the percentage of green cells.
    I dont set up a formula to look at cells that are green (since you can only do that with VBA).
    Instead I use the same condition that set the cells to be green in the first place since I know that any cell that contains 3 must automatically be green (assuming there are no additional manually coloured cells or other conditional formats that set the cells to green).

    So in this case

    =COUNTIF(A1:A100,3)/100
    would give me the number of cells in column A that contain 3 which also happens to be the number of green cells.

    All I've done is use the same condtion thats in the conditional formatting formula (is a cell equal to 3) to determine the number of green cells.


    UPDATE: By the way, your image is tiny I havent even looked at it.
    It would be better to post a spreadsheet than an image.
    Posting an image means everyone has to reenter your data to provide a working solution.
    Last edited by Special-K; 06-07-2017 at 06:55 AM.

+ 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. *NOT SOLVED!* Conditional Formatting based on two cells
    By NJS1982 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 12-01-2015, 12:21 PM
  2. Replies: 11
    Last Post: 04-17-2014, 03:07 PM
  3. [SOLVED]Conditional Formatting to Highlight Cells
    By TerryH79 in forum Excel General
    Replies: 4
    Last Post: 11-08-2011, 07:45 AM
  4. [SOLVED] [SOLVED] Hiding or Formatting non matching cells
    By A.R.J Allan Jefferys in forum Excel - New Users/Basics
    Replies: 3
    Last Post: 05-10-2006, 01:35 PM
  5. [SOLVED] [SOLVED] Formatting a row of Cells
    By DennisB in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-16-2005, 06:15 PM
  6. [SOLVED] Selecting & Formatting Columns w/ Merged Cells
    By Lisa Beach in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 10-10-2005, 06:05 PM
  7. Replies: 5
    Last Post: 04-04-2005, 10:06 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