+ Reply to Thread
Results 1 to 8 of 8

Need formula for subtraction using IF statement

  1. #1
    Registered User
    Join Date
    11-06-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    11

    Need formula for subtraction using IF statement

    Hi, Today only i joined. i need a help.
    The given formula is working but not exactly getting the output.
    My requirement is if a-b<60,b-c<60,c-a<60, print values is yes, if else print No.
    Can any one help me getting the correct formula for the above requirement.

    =(IF(((E6-F6)<C6),"Yes",IF(((F6-G6)<C6),"Yes")))

  2. #2
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: Need formula for subtraction using IF statement

    Generally:

    =IF( OR(A - B < 60, B - C < 60, C - A < 60), "Yes", "No")

    Specifically:
    =IF(OR(E6 - F6 < C6, F6 - G6 < C6, G6 - E6 < C6), "Yes", "No")

    Like that?

  3. #3
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 insider Version 2504 Win 11
    Posts
    24,704

    Re: Need formula for subtraction using IF statement

    =if(and(a-b<60,b-c<60,c-a<60),"Yes","No")

    Edit: Obviously Ben and I looked at your criteria differently. One of these two will work depending on your conditions of "Or" or "And."
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  4. #4
    Registered User
    Join Date
    11-06-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Need formula for subtraction using IF statement

    Can any one please help in this thread?

  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: Need formula for subtraction using IF statement

    have you tried the sugestions already posted? if you have and they dont work what exactly is not working
    "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
    11-06-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Need formula for subtraction using IF statement

    Thanks for your immediate reply.
    checking with the data.
    will confirm you team.

  7. #7
    Registered User
    Join Date
    11-06-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Need formula for subtraction using IF statement

    Dear Team,
    Thanks for your help.
    The given formula is working fine.

  8. #8
    Registered User
    Join Date
    11-06-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Need formula for subtraction using IF statement

    hi team,
    i want to take the count using the colour for different criteria.
    Can any one please help me in getting the data?

+ 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. [SOLVED] Subtraction Formula
    By Dowjd in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 04-23-2013, 02:12 PM
  2. [SOLVED] IF statement subtraction help.
    By Ltruong110 in forum Excel General
    Replies: 4
    Last Post: 07-22-2012, 01:18 PM
  3. subtraction formula
    By happless in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-06-2011, 05:41 PM
  4. need help with a subtraction formula
    By adelissa in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 01-10-2011, 12:57 PM
  5. [SOLVED] subtraction formula
    By Mart in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-23-2006, 07:50 AM

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