+ Reply to Thread
Results 1 to 20 of 20

Conditional Formating for a row

  1. #1
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Conditional Formating for a row

    Please see post #4 for - includeds workbook
    Last edited by SVTF; 10-12-2014 at 12:46 PM.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    1st, avoid using entire columns or rows in CF, it will slow your file down.

    2nd, try using absoluting onthe references...
    =M4= ""
    =$M4= ""
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Tried the above.

    Perhaps I am chaning the wrong values based on whay I am looking to do.

    Thoughts - Anyone else help me out?

  4. #4
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Ok revamped things ... this is for excel 2010

    Still looking for some assistance which I assume is a very easy fix.

    I have 4 rows with data in them ... to explain my issue.

    Row 4 works as it should be with exception for column G? see below
    Row 5 is not working the way I need it to
    Row 6 works as it should be with exception for column G? see below
    Row 7 works as it should be with exception for column G? see below

    Request # 1

    You will notice that the only difference when looking at the workbook is that I5 has no date (so it's a blank cell) which could happen
    There is a counter in column L ... so L5 shows 71 ...

    So when I5 happens to be blank and the counter in L - same row is > 14 I need for that entire row to turn red.

    I need to add a condition to the already 3 that are there to make the above happen.

    Request # 2

    Column G...

    Currently once the date is entered into I ... if < 14 the entire row turns green, if > 14 the entire row turns red, if the date is deleted from I then the row goes back to no color.

    But for some reason I can not get Column G to work the same way as the other cells based on the above guide lines.

    For these adjustments they need to run from Row 4:4999

    See the attached workbook

    Let me know if you have any questions

    And Thanks in advance
    Last edited by SVTF; 10-10-2014 at 10:26 PM.

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    1st, highlight all the rows in columns C:N, then select CF/Clear Rules/from selected cells

    Then adjust the "Applies to" range in the CF in B2 to be the full range you want...
    =$B$4:$N$4999

    Note that if your range does not need to be that long, shortend it to what you actually need. CF can bocome a drain on resources and slow your file down

  6. #6
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    FDibbins - Not sure your suggestion fixes what I need to do ... All other CF's are working fine.

    Please review the revamped situation - Post # 4 with workbook example

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    Row 4 works as it should be with exception for column G? see below
    for col G, you have the same CF rules in 6 times, plus it is referencing col N, not M. Is this meant to be a different rule?
    Also, like I said, instead of applying CF to each column seperately, you can use the range of all the columns in the "applies to" box

    If I understand the rest...
    Like I said, remove ALL the cf rules you currently have in A and C:N, we will make all the rules in B, and have them Apply to the whole range.
    click on B4 and go into CF
    Change all the Applied to, to =$A$4:$N$4999. If G needs a different set of rules, then use this range instead =$A$4:$F$4999,$H$4:$M$4999
    Remove the rule for turning white (=M4="") That is teh default color, you dont need a rule for that.
    For the red, use this rule...
    =AND($M4="",$L4>14,$A4<>"")
    for the green rule, use this...
    =$M4<=14
    Note the use of absoluting $ to keep column M fixed for all rules

    Now, for G, is that a different set of rules?

  8. #8
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Followed the above ... almost there ... couple of things came up.

    Thanks by the way I was looking at this for a while and could not figure out your direction in your first post.

    Did not see for what ever reason the duplicates in G & G does not need a different set of rules.
    Also discovered the reason why there was a white CF statement it was because someone had the cells filled with green by default.

    So almost there - please see below and see workbook

    So I did everything you mentioned... couple of small tweaks.

    • Row 5 & 7 should be red across the row over to M because L > 14 days
    • Anytime L is over 14 days the row should turn red.

    • The row does turn red if there is correction date in I and L is > 14 days - see row 9

    Row 8 - I would like for it to be green when this situation comes up.

    There are times where L could be equal to #N/A - this happens when the correction date is before the entry date.
    When this happens it is considered complete because there is a correction date so the row needs to turn green over to M.
    Last edited by SVTF; 10-12-2014 at 12:47 PM.

  9. #9
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    Row 5 & 7 should be red across the row over to M because L > 14 days
    so you want the row to be red is L is >14, even if M has a value?. If so then modify the red formula to this...
    =AND(or(iserror($L4,$L4>14),$A4<>"")
    This should take care of the #N/A as well

  10. #10
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Please Login or Register  to view this content.
    Error: Does not like ... too many arguments?

    A row needs to be red for two reasons ...

    If M is >14 days
    and
    If M is blank for > 14 days as per the value in L

    The original formula suggested for red above in post #7 changes the row red if L > 14 and M is blank

    M has the same value as L when there is correction date entered in I

    So need to modify the red CF you provided (post #7) to include both reasons to turn red or need another CF to turn row red if M > 14

    Regarding N/A

    I added a third simple CF to handle the N/A

    =$L4 less tha n 0
    Last edited by SVTF; 10-11-2014 at 11:39 AM.

  11. #11
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    @FDibbins when you have a moment can you have a look at my last hurdle.

  12. #12
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Anyone willing to put a fresh set of eyes on my request in post #10

    Would like to close this up tonight.

    Let me know if you have any questions.

    See workbook in post #8

    And Thanks in advance.

  13. #13
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    =AND(or(iserror($L4,$L4>14),$A4"")
    oops I left off a ) sorry

    =AND(or(iserror($L4),$L4>14),$A4"")

    actually, try this instead...
    =AND(or(iserror($M4),$M4=""),$L4>14,$A4<>"")
    Last edited by FDibbins; 10-12-2014 at 12:40 AM.

  14. #14
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    @FDibbins,

    Please Login or Register  to view this content.
    Does not produce a different result that what we have already been getting ... still only turning the row red that does not have a value in M - Row 9

    Row 5/7 are not being turned red even though the value in M is > 14

    Not sure I this matters ... there is a formula in Column M and L ... not sure if it matters.

    Thoughts?
    Last edited by SVTF; 10-12-2014 at 09:13 AM.

  15. #15
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    OK, I have come up with this...
    =AND($B4<>"",OR($M4>14,AND($B4<>"",$L4>14)))

    If that does not work, then please lay out your rules for me again. I am obviously missing something. This is how I understand it...

    turn red if
    L > 14
    M >14
    M ="" L > 14

  16. #16
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Let me post the workbook still needs a tweak.
    Last edited by SVTF; 10-12-2014 at 12:18 PM.

  17. #17
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Worked but didn't work ... See row 7 in the workbook

    L is only 1 day and it turned the row red - should not turn red till day 15

    Row only needs to turn red if

    M > 14
    M "" but L > 14
    Last edited by SVTF; 10-12-2014 at 12:36 PM.

  18. #18
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Quote Originally Posted by FDibbins View Post
    OK, I have come up with this...
    =AND($B4<>"",OR($M4>14,AND($B4<>"",$L4>14)))
    That almost worked ... the trouble was that it was changing the row red when L < 14 and M was ""

    I modified the above to
    Please Login or Register  to view this content.
    And for the moment appears to be working as needed.

    Thank you for your help - marking as solved.

    Rep Sent.

  19. #19
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Conditional Formating for a row

    OK great You probably dont need the 2nd AND, could probably just use =AND($M4>14,$B4<>"",$L4>14), but as long as its working for you

  20. #20
    Forum Contributor
    Join Date
    08-22-2005
    MS-Off Ver
    Office 365
    Posts
    342

    Re: Conditional Formating for a row

    Thanks again ... cleaned it up as your above suggestion.

+ 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: 5
    Last Post: 03-14-2014, 04:03 AM
  2. Replies: 4
    Last Post: 01-23-2014, 10:14 AM
  3. Replies: 6
    Last Post: 08-14-2006, 05:00 PM
  4. Replies: 2
    Last Post: 03-27-2006, 12:10 PM
  5. Install dates formating using conditional formating?
    By Jerry Eggleston in forum Excel General
    Replies: 2
    Last Post: 11-09-2005, 01:49 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