+ Reply to Thread
Results 1 to 6 of 6

Help with a Formula

  1. #1
    carl
    Guest

    Help with a Formula

    Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the threshold,
    the formula does not return "check". For example in:

    IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    does not equal "sell" and M1232-K1232 equals -.25 the formula does not return
    "check".

    Here's the entire formula:

    =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K1232>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

    Thank you in advance.

  2. #2
    Duke Carey
    Guest

    RE: Help with a Formula

    Try rounding, i.e.,

    IF(I1232="sell",round(K1232-L1232),round(M1232-K1232))<=-0.25)


    "carl" wrote:

    > Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the threshold,
    > the formula does not return "check". For example in:
    >
    > IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    > does not equal "sell" and M1232-K1232 equals -.25 the formula does not return
    > "check".
    >
    > Here's the entire formula:
    >
    > =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K1232>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-1)); "Check";"")
    >
    > Thank you in advance.


  3. #3
    Duke Carey
    Guest

    RE: Help with a Formula

    Try rounding, i.e.,

    IF(I1232="sell",round(K1232-L1232),round(M1232-K1232))<=-0.25)


    "carl" wrote:

    > Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the threshold,
    > the formula does not return "check". For example in:
    >
    > IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    > does not equal "sell" and M1232-K1232 equals -.25 the formula does not return
    > "check".
    >
    > Here's the entire formula:
    >
    > =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K1232>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-1)); "Check";"")
    >
    > Thank you in advance.


  4. #4
    Bob Phillips
    Guest

    Re: Help with a Formula

    I think Duke means

    IF(I1232="sell",round(K1232-L1232,0),round(M1232-K1232,0))<=-0.25)


    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "Duke Carey" <[email protected]> wrote in message
    news:[email protected]...
    > Try rounding, i.e.,
    >
    > IF(I1232="sell",round(K1232-L1232),round(M1232-K1232))<=-0.25)
    >
    >
    > "carl" wrote:
    >
    > > Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the

    threshold,
    > > the formula does not return "check". For example in:
    > >
    > > IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    > > does not equal "sell" and M1232-K1232 equals -.25 the formula does not

    return
    > > "check".
    > >
    > > Here's the entire formula:
    > >
    > >

    =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K123
    2>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1
    232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=
    20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="se
    ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")
    > >
    > > Thank you in advance.




  5. #5
    Duke Carey
    Guest

    Re: Help with a Formula

    I have to correct Bob's correction or my error

    IF(I1232="sell",round(K1232-L1232,2),round(M1232-K1232,2))<=-0.25)

    I hope we're all done with this subject


    "Bob Phillips" wrote:

    > I think Duke means
    >
    > IF(I1232="sell",round(K1232-L1232,0),round(M1232-K1232,0))<=-0.25)
    >
    >
    > --
    > HTH
    >
    > Bob Phillips
    >
    > (remove nothere from email address if mailing direct)
    >
    > "Duke Carey" <[email protected]> wrote in message
    > news:[email protected]...
    > > Try rounding, i.e.,
    > >
    > > IF(I1232="sell",round(K1232-L1232),round(M1232-K1232))<=-0.25)
    > >
    > >
    > > "carl" wrote:
    > >
    > > > Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the

    > threshold,
    > > > the formula does not return "check". For example in:
    > > >
    > > > IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    > > > does not equal "sell" and M1232-K1232 equals -.25 the formula does not

    > return
    > > > "check".
    > > >
    > > > Here's the entire formula:
    > > >
    > > >

    > =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K123
    > 2>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1
    > 232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=
    > 20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="se
    > ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")
    > > >
    > > > Thank you in advance.

    >
    >
    >


  6. #6
    Duke Carey
    Guest

    Re: Help with a Formula

    OK, I wasn't done:

    shorter version:

    ROUND(IF(I1232="sell",K1232-L1232,M1232-K1232),2)<=-0.25


    "Duke Carey" wrote:

    > I have to correct Bob's correction or my error
    >
    > IF(I1232="sell",round(K1232-L1232,2),round(M1232-K1232,2))<=-0.25)
    >
    > I hope we're all done with this subject
    >
    >
    > "Bob Phillips" wrote:
    >
    > > I think Duke means
    > >
    > > IF(I1232="sell",round(K1232-L1232,0),round(M1232-K1232,0))<=-0.25)
    > >
    > >
    > > --
    > > HTH
    > >
    > > Bob Phillips
    > >
    > > (remove nothere from email address if mailing direct)
    > >
    > > "Duke Carey" <[email protected]> wrote in message
    > > news:[email protected]...
    > > > Try rounding, i.e.,
    > > >
    > > > IF(I1232="sell",round(K1232-L1232),round(M1232-K1232))<=-0.25)
    > > >
    > > >
    > > > "carl" wrote:
    > > >
    > > > > Hi. For some reason when "K1232-L1232;M1232-K1232" is equal to the

    > > threshold,
    > > > > the formula does not return "check". For example in:
    > > > >
    > > > > IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25). In this case, if I1232
    > > > > does not equal "sell" and M1232-K1232 equals -.25 the formula does not

    > > return
    > > > > "check".
    > > > >
    > > > > Here's the entire formula:
    > > > >
    > > > >

    > > =IF(OR(AND(K1232<2;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.25);AND(K123
    > > 2>=2;K1232<=5;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.4);AND(K1232>5;K1
    > > 232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K1232>10;K1232<=
    > > 20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K1232>20;IF(I1232="se
    > > ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")
    > > > >
    > > > > Thank you in advance.

    > >
    > >
    > >


+ 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