+ Reply to Thread
Results 1 to 12 of 12

Conditional formatting a cell with division of zero error #Div/0!

  1. #1
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Conditional formatting a cell with division of zero error #Div/0!

    I want to clean up a spreadsheet so zeros or division of zeros do not appear. The way the spreadsheet is used is to first print it out as a template, then handwrite the data into the empty cells. When the data is later entered into the spreadsheet, the zeros and division by zero go away.

    The zero values I blank out by using a conditional formatting testing for zero then change the font color to white. There is probably a better way but it does work.
    However, this method does not work for a cell with a division by zero error [#Div/0!] How can I hide this temporary situation before the additional data is entered which makes the data go away?

    Thanks for any ideas.

    t

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    are there a lot of formulas
    you could add an IFERROR or other error correction, BUT it will need to be done to ALL formulas that return #Div/0!
    otherwise the conditional formatting is probably a quick solution - to test the cell for an Error & change the font to white for printing
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Re: Conditional formatting a cell with division of zero error #Div/0!

    There are a bunch of formulas in variuos areas which I did not deveolp, dont have complete mastery of the whole sheet - would shy away from a global approach. How exactly would I test for error in say cell A1?

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    depending on the formula in A1
    but IFERROR( formula, "")

  5. #5
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Re: Conditional formatting a cell with division of zero error #Div/0!

    Excellent thanks.

  6. #6
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    your welcome
    if my assistance has helped, and only if you wish to , there is a reputation icon * on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  7. #7
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Re: Conditional formatting a cell with division of zero error #Div/0!

    I'm still not there in this situation, although I like the IF ERROR(formula,"") technique. My cell, let’s call it A1, needs to appear blank when there is a division by zero. In this cell there is a reference to another cell i.e. “=Z1.” I don’t want to touch cell Z1.

    Not sure how I use the =Z1 with the IFERROR. I tried [IF ERROR(=Z1,"")].
    Last edited by JET2011; 03-11-2015 at 10:02 AM. Reason: typo

  8. #8
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    assuming the formula is =B1/C1 in A1
    then rather than a Div0 error you can use iferror like this
    in A1 you replace =B1/C1 with
    =IFERROR(B1/C1,"")

  9. #9
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Re: Conditional formatting a cell with division of zero error #Div/0!

    The formula is =Z1 in cell A1

  10. #10
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    then in A1 put

    =IFERROR(Z1,"")

  11. #11
    Forum Contributor
    Join Date
    01-30-2011
    Location
    Boston
    MS-Off Ver
    MS 365
    Posts
    225

    Re: Conditional formatting a cell with division of zero error #Div/0!

    Nice ! I'll be using that one a lot! Thanks agian.

    t

  12. #12
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,795

    Re: Conditional formatting a cell with division of zero error #Div/0!

    your welcome
    if my assistance has helped, and only if you wish to , there is a reputation icon * on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

+ 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: 1
    Last Post: 11-21-2013, 01:16 PM
  2. [SOLVED] Cell Reference Error use for conditional formatting
    By ahilty in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-09-2013, 02:37 PM
  3. [SOLVED] Conditional Formatting - Highlight All Rows in Table with Error in Any Cell
    By jgray in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 03-18-2013, 05:04 PM
  4. Cell references error with recorded Conditional Formatting (Formula) macro
    By nlexcel in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-23-2012, 01:38 PM
  5. Blank cell shows error on division.
    By Hatchiman in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-28-2010, 01:20 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