+ Reply to Thread
Results 1 to 8 of 8

sumproduct multiply if > 0

  1. #1
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    sumproduct multiply if > 0

    Hi all, could you helpo me with this?

    =SUMPRODUCT((L5:L9)*(L5:L9>0)) but it's suming the numbers instead of multiplying them!

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

    Re: sumproduct multiply if > 0

    Can you post some sample data...and the results you want to calculate?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  3. #3
    Registered User
    Join Date
    01-24-2009
    Location
    Leicester, England
    MS-Off Ver
    Excel 2003 &2007
    Posts
    27

    Re: sumproduct multiply if > 0

    I think that your formula shoulb be:

    =SUMPRODUCT(L5:L9,L5:L9)

    to give the sum of each number multiplied by itself.

    EllBol.

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: sumproduct multiply if > 0

    Perhaps =PRODUCT(IF(L5:L9>0, L5:L9))

    Confirmed with Ctrl+Shift+Enter, rather than just Enter.
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: sumproduct multiply if > 0

    =PRODUCT(IF(A1:A9=0,1,A1:A9))
    array entered should give the desired result(it allows for -ve values)
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  6. #6
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    Re: sumproduct multiply if > 0

    Thanks for replying, see attached an example
    Attached Files Attached Files

  7. #7
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: sumproduct multiply if > 0

    then either shg's or mine will work

    =PRODUCT(IF(F3:F7=0,1,F3:F7))
    or
    =PRODUCT(IF(F3:F7>0, F3:F7))
    Dont forget to array enter with ctrl+shift+enter
    see how to enter array formula link in my signature

  8. #8
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    Re: sumproduct multiply if > 0

    Thanks very much

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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