ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   decision Box Y (https://www.excelbanter.com/excel-worksheet-functions/212588-decision-box-y.html)

Scoober

decision Box Y
 
How do i put a formula that recognises a 'yes' or 'no' answer?

e.g X Y Z

1 10,000 No 0.000

If Y1 has 'No' printed in it then 0.000 is printed in Z1

However if 'Y1' has 'yes' printed in it I need a formula of =sum(X1*0.03) to
be completed (see below).

e.g X Y Z

1 10,000 yes 300

Can anybody help?







JE McGimpsey

decision Box Y
 
One way:

Z1: =IF(Y1="Yes", X1 * 0.03, 0)

An alternative:

Z1: =X1 * 0.03 * (Y1="Yes")


The latter works because if "Yes" is in Y1, then 'Y1="Yes"' returns TRUE
which in math formulae is converted by XL to the value 1 (FALSE is
converted to 0).

In article ,
Scoober wrote:

How do i put a formula that recognises a 'yes' or 'no' answer?

e.g X Y Z

1 10,000 No 0.000

If Y1 has 'No' printed in it then 0.000 is printed in Z1

However if 'Y1' has 'yes' printed in it I need a formula of =sum(X1*0.03) to
be completed (see below).

e.g X Y Z

1 10,000 yes 300

Can anybody help?





Scoober

decision Box Y
 
Thank you JE that worked straigjht away.

"JE McGimpsey" wrote:

One way:

Z1: =IF(Y1="Yes", X1 * 0.03, 0)

An alternative:

Z1: =X1 * 0.03 * (Y1="Yes")


The latter works because if "Yes" is in Y1, then 'Y1="Yes"' returns TRUE
which in math formulae is converted by XL to the value 1 (FALSE is
converted to 0).

In article ,
Scoober wrote:

How do i put a formula that recognises a 'yes' or 'no' answer?

e.g X Y Z

1 10,000 No 0.000

If Y1 has 'No' printed in it then 0.000 is printed in Z1

However if 'Y1' has 'yes' printed in it I need a formula of =sum(X1*0.03) to
be completed (see below).

e.g X Y Z

1 10,000 yes 300

Can anybody help?







All times are GMT +1. The time now is 09:13 AM.

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