+ Reply to Thread
Results 1 to 7 of 7

Division by empty cells

  1. #1
    Registered User
    Join Date
    06-21-2013
    Location
    zagreb
    MS-Off Ver
    Excel 2010
    Posts
    23

    Division by empty cells

    Hi,

    I am new here and just starting with excel. I have six empty cells, let say cells: A1,B1,C1,D1,E1 and F1. I need to make formula that calculates 1/A1+1/B1+1/C1+1/D1+1/E1+1/F1. Obviously it works fine when there are numbers in all cells but if only one cell is empty formula wont work. Could someone please assist. Tnx

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,428

    Re: Division by empty cells

    What do you want to happen if one or more of the cells is blank.

    If they all have to be present, you could just have something like:

    =IFERROR( ... your formula ... , "data missing; please review")


    Regards, TMS
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: Division by empty cells

    Try this ARRAY FORMULA, completed by holding down CTRL and SHIFT when you press ENTER (instead of just pressing ENTER)
    =SUM(IFERROR(1/A1:F1,0))

    EDITED TO INCLUDE THIS:
    I just thought of a way to achieve that sum using a regular formula:
    =SUMPRODUCT((A1:F1<>"")/(A1:F1+(A1:F1="")))

    Is that something you can work with?
    Last edited by Ron Coderre; 07-21-2013 at 06:27 PM.
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  4. #4
    Registered User
    Join Date
    06-21-2013
    Location
    zagreb
    MS-Off Ver
    Excel 2010
    Posts
    23

    Re: Division by empty cells

    Yes, this formula works perfect. Could I just border you with few more questions. I presume IFERROR function when it gets to empty cells and tries to divide with them just returns value if error(in this case 0) but what is the difference between CRTL+SHIFT+ENTER and just ENTER. Once again many thanks.

  5. #5
    Registered User
    Join Date
    06-21-2013
    Location
    zagreb
    MS-Off Ver
    Excel 2010
    Posts
    23

    Re: Division by empty cells

    Yes that second formula also works fine. Once again thank you.

  6. #6
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: Division by empty cells

    While the explanation is complicated, it's easier to just say that some formulas only work when you use CTRL+SHIFT+ENTER.
    Any easy way to spot those formulas is...
    • Select the cell containing the formula that resolves to an error or an unexpected value
    • Press F2...Press: F9
    If the correct result displays, C+S+E will probably make the formula functional.
    • Press ESC to restore the formula.

  7. #7
    Registered User
    Join Date
    06-21-2013
    Location
    zagreb
    MS-Off Ver
    Excel 2010
    Posts
    23

    Re: Division by empty cells

    I'll need some time to figure out second formula as I am not sure what is multiplied by what. Tnx.

+ 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. division gives wrong answer (division)
    By Brice in forum Excel General
    Replies: 5
    Last Post: 12-24-2010, 10:13 PM
  2. division between cells
    By nclark in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 12-11-2009, 09:02 PM
  3. Division Of Range Of Cells..help!!
    By CLAYTONAPPLIANC in forum Excel General
    Replies: 1
    Last Post: 10-03-2006, 10:12 AM
  4. macro to colour empty cells (cells not recognized as empty)
    By Gerben in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-30-2005, 11:05 AM
  5. [SOLVED] Auto populate cells based on 2 cells division.
    By Chance224 in forum Excel General
    Replies: 0
    Last Post: 04-04-2005, 05:06 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