+ Reply to Thread
Results 1 to 4 of 4

Sum two cells if one cell has certain value

  1. #1
    Registered User
    Join Date
    07-29-2016
    Location
    dallas, tx
    MS-Off Ver
    365
    Posts
    51

    Sum two cells if one cell has certain value

    I am trying to sum two values (V4:W4) only if the value of V4 exceeds 0.

    The formula for this is in T4, but I keep getting a #value! error, no matter how I work it.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    V4 has a formula to count J4:K4 only if the value is >=2.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    W4 has a formula to count L4:R4 only if any of the values are >=2.
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    The reason there are two separate formulas for J4:K4 and L4:R4 is because I cannot count L4:R4 unless this is a value of 2 or greater in at least J4 or K4.

    Thanks for any input in advance!

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Sum two cells if one cell has certain value

    for the sum if V4 is greater than 0, try this... =IF($V$4>0,SUM($V$4:$W$4),"")
    not clear on what question you have on the other formulas.
    Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
    Sam Capricci

  3. #3
    Registered User
    Join Date
    07-29-2016
    Location
    dallas, tx
    MS-Off Ver
    365
    Posts
    51

    Re: Sum two cells if one cell has certain value

    Quote Originally Posted by Sambo kid View Post
    for the sum if V4 is greater than 0, try this... =IF($V$4>0,SUM($V$4:$W$4),"")
    not clear on what question you have on the other formulas.
    Now I see where I went wrong. Your formula works perfect. The reason for posting the other formulas is to show what was in those cells that I was trying to sum, in case my error had something to do with it.

    Thank you again!!

  4. #4
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Sum two cells if one cell has certain value

    You're welcome. AND, thank you for the rep!

+ 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: 01-25-2019, 06:18 AM
  2. Replies: 5
    Last Post: 04-06-2018, 12:48 AM
  3. [SOLVED] Search Range for NonBlank Cells, Fill Down only one cell below NOT all Blank cells belof
    By safari20WDG in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 09-07-2017, 01:23 AM
  4. [SOLVED] Search range of cells, return cell locations of all cells of particular colour
    By AJB611 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-03-2017, 11:50 AM
  5. Move cells based on cell length *shift cells right) - code required
    By pauldaddyadams in forum Excel Programming / VBA / Macros
    Replies: 49
    Last Post: 11-21-2014, 08:56 AM
  6. [SOLVED] Count cells in row based on cell value, highlight row if wrong number or cells.
    By gutterball in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 09-11-2014, 04:00 PM
  7. Replies: 0
    Last Post: 04-07-2009, 04:42 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