+ Reply to Thread
Results 1 to 9 of 9

How to calculate a Sum when its an empty cell?

  1. #1
    Registered User
    Join Date
    04-07-2023
    Location
    Stuttgart
    MS-Off Ver
    O365
    Posts
    1

    How to calculate a Sum when its an empty cell?

    I am using the following formula to calculate Project velocity (hours spent on project) using index and match to take a letter and give it a value. However, the only only way I could make it work was to put a "space" in all the empty cells and make the "space" a value of 0. Is there a way I can make this work with out the spaces?

    =SUM(INDEX($N22:$N26,N(IF(1,MATCH(B3:B27,$M22:$M26,0)))))



    Thank you
    Attached Files Attached Files
    Last edited by rlcass; 04-11-2023 at 02:53 AM.

  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,447

    Re: How to calculate a Sum when its an empty cell?

    Try

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    You’ll need to clear all the "spaces".
    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 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,447

    Re: How to calculate a Sum when its an empty cell?

    See attached updated example.
    Attached Files Attached Files

  4. #4
    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,447

    Re: How to calculate a Sum when its an empty cell?

    Thanks for the rep.



    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.

  5. #5
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Australia
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,423

    Re: How to calculate a Sum when its an empty cell?

    Cell K28 formula

    SUM
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by wk9128; 04-11-2023 at 03:10 AM.

  6. #6
    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,447

    Re: How to calculate a Sum when its an empty cell?

    This would work too:

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  7. #7
    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,447

    Re: How to calculate a Sum when its an empty cell?

    @wk9128: maybe B28?

  8. #8
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Australia
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,423

    Re: How to calculate a Sum when its an empty cell?

    @TMS your eyes are too sharp, Thanks for your help correcting me

    Cell B28 formula , Drag down and across
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by wk9128; 04-11-2023 at 05:06 AM.

  9. #9
    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,447

    Re: How to calculate a Sum when its an empty cell?

    You're welcome.

    I like the single formula approach

+ 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. Calculate while ignoring the empty cell
    By stk14june in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 5
    Last Post: 06-06-2022, 01:40 AM
  2. Calculate while ignoring the empty cell
    By stk14june in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-05-2022, 03:57 AM
  3. Calculate while ignoring the empty cell
    By stk14june in forum F1 Get the Most out of Excel! The Ultimate Excel Tip Help Guide
    Replies: 0
    Last Post: 06-05-2022, 03:55 AM
  4. [SOLVED] Function still calculate when cell is empty
    By andsalex in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-18-2020, 03:57 AM
  5. [SOLVED] IF cell is empty do not calculate
    By Dandrewhill in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-03-2016, 09:22 PM
  6. don't calculate row using macro and move to next row if specified cell is empty
    By IrishMist1748 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-17-2014, 07:01 PM
  7. calculate sum in between 2 empty cell
    By Rick in forum Excel General
    Replies: 7
    Last Post: 08-12-2006, 06:45 AM

Tags for this Thread

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