+ Reply to Thread
Results 1 to 5 of 5

Conditional formatting is highlighting empty cells that contain formula

  1. #1
    Registered User
    Join Date
    10-10-2012
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    65

    Conditional formatting is highlighting empty cells that contain formula

    Hi guys

    I am using conditional formatting on cells which show % growth YoY for sales figures

    The formula in those cells is basically IFERROR((F38-C38)/C38,"")

    So any cells which give an error are blank

    When applying conditional formatting, i am using Green for IF J38>0,
    Red for IF J38<0

    But those cells which are returining "" are also being highlighted green.

    I cant figure out why and its so annoying

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,447

    Re: Conditional formatting is highlighting empty cells that contain formula

    As the cells contain a null text string, XL finds it larger than 0 as it first does a TYPE() comparison and when the content is text TYPE returns 2 which is larger than 1 ( TYPE value for number)
    To XL text is always larger than any number
    Check the " Stop if true" box after the IFERROR part
    or use =AND(J38>0,J38<>"") for green

  3. #3
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,447

    Re: Conditional formatting is highlighting empty cells that contain formula

    BTW are you still using XL2003 ( I suspect not as you are using IFERROR)? If not update your profile as answers are tailored to the XL version you are using

  4. #4
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481

    Re: Conditional formatting is highlighting empty cells that contain formula

    Hi there,

    Using the following formula for conditional formatting works for me:

    Please Login or Register  to view this content.

    Hope this helps.

    Regards,

    Greg M

  5. #5
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,447

    Re: Conditional formatting is highlighting empty cells that contain formula

    Thanks for updating your profile

+ 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. Conditional Formatting with a Formula, it's highlighting incorrect cells
    By Hyflex in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-05-2019, 01:43 AM
  2. Replies: 3
    Last Post: 10-22-2018, 02:54 PM
  3. highlighting cells using conditional formatting
    By kennylarid in forum Excel General
    Replies: 2
    Last Post: 07-28-2015, 07:47 AM
  4. Replies: 1
    Last Post: 07-11-2014, 12:37 PM
  5. [SOLVED] Conditional Formatting with highlighting different cells
    By Kristenmrn in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-28-2012, 11:34 AM
  6. Conditional Formatting: Highlighting exactly the top 10 cells
    By scotslad7 in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 02-08-2011, 12:47 AM
  7. highlighting the cells using conditional formatting
    By darkhangelsk in forum Excel General
    Replies: 2
    Last Post: 08-19-2009, 10:46 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