ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   formula correction (https://www.excelbanter.com/excel-worksheet-functions/7477-formula-correction.html)

Roccobarocco

formula correction
 
Can anyone correct the following formula:

=IF(J20="w",a!BT20,IF(J20="l",a!BT20,IF(J20="x",0, IF(J20="",a!BT20,0,if(K20="X",0))))

,or suggest an alternative?

tjtjjtjt

I'm not quite sure exactly what you want. Could you describe exactly what you
would like to see happen, including which logical tests should take
precedence?
Or, you may want to look in the Help Files at the OR and AND Functions.

tj

"Roccobarocco" wrote:

Can anyone correct the following formula:

=IF(J20="w",a!BT20,IF(J20="l",a!BT20,IF(J20="x",0, IF(J20="",a!BT20,0,if(K20="X",0))))

,or suggest an alternative?


Arvi Laanemets

Hi

=IF(J20="x","",IF(OR(J20="w",J20="l",J20=""),a!BT2 0,IF(K20="X",0,"")))


Arvi Laanemets


"Roccobarocco" wrote in message
...
Can anyone correct the following formula:


=IF(J20="w",a!BT20,IF(J20="l",a!BT20,IF(J20="x",0, IF(J20="",a!BT20,0,if(K20=
"X",0))))

,or suggest an alternative?




Ron Rosenfeld

On Sun, 5 Dec 2004 12:59:05 -0800, Roccobarocco
wrote:

Can anyone correct the following formula:

=IF(J20="w",a!BT20,IF(J20="l",a!BT20,IF(J20="x",0 ,IF(J20="",a!BT20,0,if(K20="X",0))))

,or suggest an alternative?


Perhaps:

=IF(J20="w",a!BT20,
IF(J20="l",a!BT20,
IF(J20="x",0,
IF(J20="",a!BT20,
IF(K20="X",0)))))

or (simpler):

=IF(OR(J20={"w","l",""}),a!BT20,IF(J20="x",0,IF(K2 0="X",0)))

Note that there are a number of things that J20 might contain that are
undefined, in which case the formula will return FALSE.



--ron

Ron Rosenfeld

On Sun, 05 Dec 2004 17:01:29 -0500, Ron Rosenfeld
wrote:

Note that there are a number of things that J20 might contain that are
undefined, in which case the formula will return FALSE.


That should read "... J20 and K20 might contain ..."


--ron


All times are GMT +1. The time now is 06:33 AM.

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