+ Reply to Thread
Results 1 to 7 of 7

Count Cell with Background color

  1. #1
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Count Cell with Background color

    HellO:

    Please refer to attached sheet.

    I need a VB Macro or formula which will perform the following:

    I have weekly color coded schedule.
    For a particular date in column C:I, i need the AM Count,Mid Count and PM Count

    Each cell is colored for AM,Mid and PM shift.
    I need the count for each shift in Cell C4:I6, based on color in cell C7:I29

    Please let me know if any questions.

    Thank you

    Riz Momin
    Attached Files Attached Files
    Last edited by rizmomin; 07-16-2013 at 05:29 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Re: Count Cell with Background color

    Hello;

    Can any one help with this one.

    Thank you

  3. #3
    Forum Contributor
    Join Date
    07-24-2012
    Location
    Denver, CO
    MS-Off Ver
    365
    Posts
    230

    Re: Count Cell with Background color

    What classifes something as AM, Mid, and PM?
    ~~LaffyAffy13~~

    If I have helped you solve your problem, please be sure to click at the bottom left of my post.

    Thanks.

  4. #4
    Forum Contributor
    Join Date
    08-08-2005
    Location
    Kansas, USA
    MS-Off Ver
    2016
    Posts
    293

    Re: Count Cell with Background color

    Riz:

    While you can count colors using the Range.Interior property, that won't work if you are coloring cells via conditional formatting.

    Suggest you just include a CountIf function in C4: I6 to count the number of cells meeting the cirteria you are using to set teh conditional formatting. Then no macro is required.

  5. #5
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Re: Count Cell with Background color

    Hi gjcase:

    I am using conditional formatting to color the cell.
    So please help me with the Countif functions.

    Thank you

    Riz Momin

  6. #6
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Count Cell with Background color

    Hello Riz,

    I have added a few SUMPRODUCT formulas in cells C4:I6 to count the colored cells. It does not really count the colors, it checks that the cells contain the times you specified in your conditional formatting rules.
    Attached Files Attached Files
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  7. #7
    Valued Forum Contributor
    Join Date
    01-18-2007
    Location
    Georgia
    MS-Off Ver
    2010
    Posts
    4,434

    Re: Count Cell with Background color

    Hi Leith:

    This will work great for me.
    Thank you so much for your great hep.

    Riz Momin

+ 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. Replies: 4
    Last Post: 12-29-2013, 11:41 PM
  2. VBA Module counts background color, would like it to count font color
    By LawBeforeGrace in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-25-2013, 08:11 AM
  3. Replies: 6
    Last Post: 11-07-2012, 10:46 AM
  4. [SOLVED] How do you count cells with background color yellow?
    By Stephanie D in forum Excel General
    Replies: 6
    Last Post: 10-18-2005, 12:05 AM
  5. [SOLVED] Need help with complicated use of count background color of Cell
    By Jane in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 08-08-2005, 12: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