If-Then Statements
For Cell C1: IF Cell A1= "W", Then C1=B1/4.
IF Cell A1= "BW", Then C1=B1/2 IF Cell A1= "SM", Then C1 = B1/2 IF Cell A1= "M", Then C1 = B1 How do I write an if statement in C1 so that it will return these varied values of B1 depending on the text in A1? Thanks |
In cell C1, put the formula:
=IF(A1="W",B1/4, IF(A1="BW", B1/2, IF(A1="SM", B1/2, IF(A1="M",B1,"error?")))) Regards Trevor "sbruner" wrote in message ... For Cell C1: IF Cell A1= "W", Then C1=B1/4. IF Cell A1= "BW", Then C1=B1/2 IF Cell A1= "SM", Then C1 = B1/2 IF Cell A1= "M", Then C1 = B1 How do I write an if statement in C1 so that it will return these varied values of B1 depending on the text in A1? Thanks |
One way:
=IF(A1="W",B1/4,IF(OR(A1="BW",A1="SM"),B1/2,IF(A1="M",B1,""))) In article , "sbruner" wrote: For Cell C1: IF Cell A1= "W", Then C1=B1/4. IF Cell A1= "BW", Then C1=B1/2 IF Cell A1= "SM", Then C1 = B1/2 IF Cell A1= "M", Then C1 = B1 How do I write an if statement in C1 so that it will return these varied values of B1 depending on the text in A1? Thanks |
All times are GMT +1. The time now is 12:58 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com