ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Help with a Formula (https://www.excelbanter.com/excel-worksheet-functions/70918-help-formula.html)

carl

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(K12325;K1232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K123210;K1232<=20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K123220;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

Thank you in advance.

Duke Carey

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(K12325;K1232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K123210;K1232<=20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K123220;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

Thank you in advance.


Bob Phillips

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" wrote in message
...
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(K12325;K1
232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K123210;K1232<=
20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K123220;IF(I1232="se
ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

Thank you in advance.




Duke Carey

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" wrote in message
...
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(K12325;K1
232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K123210;K1232<=
20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K123220;IF(I1232="se
ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

Thank you in advance.





Duke Carey

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" wrote in message
...
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(K12325;K1
232<=10;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.5);AND(K123210;K1232<=
20;IF(I1232="sell";K1232-L1232;M1232-K1232)<=-0.8);AND(K123220;IF(I1232="se
ll";K1232-L1232;M1232-K1232)<=-1)); "Check";"")

Thank you in advance.






All times are GMT +1. The time now is 12:00 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com