+ Reply to Thread
Results 1 to 2 of 2

Changing the fill colour of cells, based on other cell inputs. #VALUE! error.

  1. #1
    Registered User
    Join Date
    06-20-2014
    Location
    England
    MS-Off Ver
    2010
    Posts
    10

    Changing the fill colour of cells, based on other cell inputs. #VALUE! error.

    Hi.

    I have a calendar set up with dates going along P6:CU6. Column C9:C27 has various status' for the job such as "Complete" or "In Progress" etc. Next to that in rows D and E I have start and end dates for the job. What I am trying to do is change the fill colour of the empty cells that are in line with each job, so that between the correct dates they are the corresponding colour to the status. So a complete job on row 9 that started on 26/05/14 and finished on 28/05/14 would have three green cells along Q9, R9, and S9.

    I have tried an IF/AND/OR statement which looks like this:

    =IF(AND(Q6>=D9,Q6<=E9),OR(IF(C9="Planned","P",""),IF(C9="In Progress","IP",""),IF(C9="Late","L",""),IF(C9="Complete","C","")),"")

    I am getting a #VALUE! data type error, I have tried reformatting the cells to various date formats but no luck so far. This could be because my dates are set up as =P6+1 etc. but I am not sure. The error only occurs when the cell falls within the dates, otherwise it remains blank.

    I intend to hide the value in the cell and use conditional formatting to change the cell colour based on the hidden input.

    Once this is working I also need to take weekends into account, column G has any 2 value combination of Y and N to say whether the employee is working Saturday, Sunday or both (poor guy). Row 7 has a "1" value underneath every Saturday and a "2" underneath every Sunday. I can imagine how this would work but combining it with the above formula could be complicated.

    I am fairly new to excel as you can probably tell so any tips, pointers or suggestions would be appreciated. Let me know if I haven't given enough information to solve.
    Thanks.

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

    Re: Changing the fill colour of cells, based on other cell inputs. #VALUE! error.

    Use condtional formatting

    Select a range of cells you want to change colour
    New Rule
    Use a formula to determine...

    =(AND(Q9>=D9,Q6<=E9,C9="Planned"))
    format as required

    Create new rules for

    =(AND(Q9>=D9,Q6<=E9,C9="In Progress"))
    format as required

    =(AND(Q9>=D9,Q6<=E9,C9="Late"))
    format as required

    =(AND(Q9>=D9,Q6<=E9,C9="Complete"))
    format as required
    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.

+ 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. Changing the fill colour of 2 other cells based on another cell's outcome
    By Danny1982 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 05-29-2014, 11:22 AM
  2. Changing cell fill colour based on date in cell - Multiple rows
    By ExcelNewb2010 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-26-2010, 07:30 AM
  3. Automatically Changing fill colour in cells
    By frazzled in forum Excel General
    Replies: 3
    Last Post: 08-29-2009, 03:28 PM
  4. changing a cell depending on the fill colour of adjacent cells
    By debbiec in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-21-2009, 06:11 AM
  5. Changing Cell Fill Colour based on another cell value
    By MoonWeazel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-02-2008, 10:15 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