+ Reply to Thread
Results 1 to 9 of 9

Help to Make IF AND Formula Return Expected Result

  1. #1
    Registered User
    Join Date
    10-24-2020
    Location
    New Zealand
    MS-Off Ver
    2019
    Posts
    16

    Question Help to Make IF AND Formula Return Expected Result

    Need some help with this. I've got most of the formula, but since I'm new to this, I can't figure out what to do. Here's what I've got so far:

    =IF(AND(M6=N6,O6=P6,Q6<=R6,S6<=3),$D$4*K6-$D$4)

    But also I need: or if S6 is greater than 3, then =LOSS

    I'm sure this is doable, but I'm new to this and need some help.

    Thanks.
    Last edited by acmarston; 10-17-2021 at 05:31 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,882

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    Administrative Note:

    We would very much like to help you with your query, however the thread title does not really convey what your request is about. Tell us what you are trying to do, not how you think it should be done.

    Please take a moment to amend your thread title. Make sure that the title properly explains your request. Your title should be explicit and not be generic (this includes function names used without an indication of what you are trying to achieve).

    Please see Forum Rule #1 about proper thread titles and adjust accordingly. To edit the thread title, open the original post to edit and then click on Go Advanced (bottom right) to access the area where you can edit your title.

    (Note: this change is not optional. As a courtesy, I have done it for you this time.)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,882

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    Try this:

    =IF(S6>3,"LOSS",IF(AND(M6=N6,O6=P6,Q6<=R6,S6<=3),$D$4*K6-$D$4))

  4. #4
    Registered User
    Join Date
    10-24-2020
    Location
    New Zealand
    MS-Off Ver
    2019
    Posts
    16

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    This didn't work, but I was able to adjust it, now it does exactly what I need it to. Here's the working formula:

    =IF(AND(M6=N6,O6=P6,Q6<=R6,S6>3),"LOSS",IF(AND(M6=N6,O6=P6,Q6<=R6,S6<=3),$D$4*K6-$D$4))

    One more thing though I'd like to change about it is, instead of some of the cells resulting in 'FALSE', how can I make it so they're just left blank?


    Thanks.
    Last edited by AliGW; 10-17-2021 at 06:07 AM. Reason: PLEASE don't quote unnecessarily!

  5. #5
    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,206

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    Try

    =IF(AND(M6=N6,O6=P6,Q6<=R6),IF(S6>3,"LOSS",$D$4*(K6-1)),"")
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,882

    Re: Help to Make IF AND Formula Return Expected Result

    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 all those who offered help.

  7. #7
    Registered User
    Join Date
    10-24-2020
    Location
    New Zealand
    MS-Off Ver
    2019
    Posts
    16

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    Quote Originally Posted by JohnTopley View Post
    Try

    =IF(AND(M6=N6,O6=P6,Q6<=R6),IF(S6>3,"LOSS",$D$4*(K6-1)),"")
    Thank you. Does exactly what I need.

  8. #8
    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,206

    Re: Helpt o Make IF AND Formula Retrun Expected Result

    You're welcome and thank you for the rep.

  9. #9
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,882

    Re: Help to Make IF AND Formula Return Expected Result

    What he said.

+ 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