+ Reply to Thread
Results 1 to 6 of 6

Do a Sumif. Use that value if it's less than another cell, otherwise insert another value

  1. #1
    Forum Contributor
    Join Date
    11-26-2008
    Location
    UK
    MS-Off Ver
    Using Excel 2019
    Posts
    317

    Do a Sumif. Use that value if it's less than another cell, otherwise insert another value

    Hi,

    I have the following but it doesn't work.

    =IF(SUMIF(Q3:Q200, B25,R3:R200) < E25, SUMIF(Q3:Q200, B25,R3:R200), K11)

    Im sure this is obvious, but I can't work it out despite trying for an hour!

    *sigh*
    Attached Files Attached Files
    Last edited by Barking_Mad; 05-25-2018 at 06:36 AM.

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,151

    Re: Do a Sumif. Use that value if it's less than another cell, otherwise insert another va

    but it doesn't work.
    meaning ????


    Attach a sample workbook (not image).so that we do not have to manually key in your data to do a testing.

    Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate.

    Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.

  3. #3
    Forum Contributor
    Join Date
    11-26-2008
    Location
    UK
    MS-Off Ver
    Using Excel 2019
    Posts
    317

    Re: Do a Sumif. Use that value if it's less than another cell, otherwise insert another va

    Apologies, see original post.

    Thanks

  4. #4
    Forum Contributor
    Join Date
    11-26-2008
    Location
    UK
    MS-Off Ver
    Using Excel 2019
    Posts
    317

    Re: Do a Sumif. Use that value if it's less than another cell, otherwise insert another va

    Quote Originally Posted by JohnTopley View Post
    meaning ????


    Attach a sample workbook (not image).so that we do not have to manually key in your data to do a testing.

    Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate.

    Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    Editing Q13 makes no difference to the output. I suspect Im using SUMIFS wrong, but I couldnt find a phrasing and answer to the way I wanted to do it.

    Thanks

  5. #5
    Forum Expert
    Join Date
    10-10-2016
    Location
    Sheffield
    MS-Off Ver
    365 and rarely 2016
    Posts
    3,210

    Re: Do a Sumif. Use that value if it's less than another cell, otherwise insert another va

    Your example doesn't correspond to the text in your post and you have not said what the result should be. It might be

    =IF(SUMIF(M11:M14,I11,N11:N14)<K11,SUMIF(M11:M14,I11,N11:N14),K11)

    but you have provided scant information

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Do a Sumif. Use that value if it's less than another cell, otherwise insert another va

    Based on the formula in yor file...
    =IF(SUMIF(N11:N14,M11:M14,I11)<K11,SUMIF(N11:N14,M11:M14),Q13)

    The syntax for both your SUMIF's are incorrect
    Syntax is...
    =SUMIF(Criteria-range, CRITERIA, sum-range)
    The 1st sumif, you have the criteria and sum range swapped around, 2nd sumif, you have no criteria
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ 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. SUMIF using or from another cell
    By mrhaugland in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 09-28-2017, 11:20 AM
  2. SUMIF cell next to it also has a value >0
    By ld2x07 in forum Excel General
    Replies: 3
    Last Post: 05-10-2014, 07:29 PM
  3. [SOLVED] sumif i know , sumif with fix cell i dont know
    By makinmomb in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-05-2014, 04:22 PM
  4. [SOLVED] Shorten SUMIF + SUMIF + SUMIF each with same reference range but different criteria???
    By HeyInKy in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-13-2014, 09:25 PM
  5. Replies: 2
    Last Post: 09-06-2012, 08:31 AM
  6. Help using SUMIF and SUM in one cell
    By LGexcel in forum Excel General
    Replies: 2
    Last Post: 04-08-2012, 09:52 PM
  7. Can you SUMIf twice in one Cell?
    By needhelp55 in forum Excel General
    Replies: 2
    Last Post: 04-20-2010, 04:14 PM

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