Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default If function with and

What is the function if I both columns says "OPEN". If a cell in Column A is
"OPEN" and a cell in column B is "OPEN", then the result in a cell in Column
C should be 1. Otherwise, the result will be 0.

Example:

Column A Column B Column C
1 OPEN OPEN 1
2 OPEN Closed 0
3 open open 1
4 closed open 0

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 964
Default If function with and

Try this:

=IF(AND(A1="OPEN",B1="OPEN"),1,0)

HTH,
Elkar


"dereksmom" wrote:

What is the function if I both columns says "OPEN". If a cell in Column A is
"OPEN" and a cell in column B is "OPEN", then the result in a cell in Column
C should be 1. Otherwise, the result will be 0.

Example:

Column A Column B Column C
1 OPEN OPEN 1
2 OPEN Closed 0
3 open open 1
4 closed open 0

Thanks

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 740
Default If function with and

dereksmom.

Column A Column B Column C
1 OPEN OPEN 1
2 OPEN Closed 0
3 open open 1
4 closed open 0


eg on C1:
=(A1="OPEN")*(B1="OPEN")

assuming that if "closed" appears on A1 or B1, Result is 0...




--
regards,
driller

*****
- dive with Jonathan Seagull



"dereksmom" wrote:

What is the function if I both columns says "OPEN". If a cell in Column A is
"OPEN" and a cell in column B is "OPEN", then the result in a cell in Column
C should be 1. Otherwise, the result will be 0.

Example:

Column A Column B Column C
1 OPEN OPEN 1
2 OPEN Closed 0
3 open open 1
4 closed open 0

Thanks

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 733
Default If function with and

dereksmom wrote...
. . . If a cell in Column A is
"OPEN" and a cell in column B is "OPEN", then the result in a cell
in Column C should be 1. Otherwise, the result will be 0.

....

One way

C2:
=--(COUNTIF(A2:B2,"OPEN")=2)

and another

C2:
=--AND(A2="OPEN",B2="OPEN")

Latter is shorter with 2 cells, but former becomes more compact with 3
or more cells.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to combine an IF Function with a lookup function to determine [email protected] Excel Worksheet Functions 1 December 5th 06 06:09 AM
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) [email protected] Excel Worksheet Functions 0 September 5th 06 03:44 PM
Offset function with nested match function not finding host ss. MKunert Excel Worksheet Functions 1 March 21st 06 10:46 PM
Emulate Index/Match combo function w/ VBA custom function Spencer Hutton Excel Worksheet Functions 2 May 2nd 05 05:26 PM
Nested IF Function, Date Comparing, and NetworkDays Function carl Excel Worksheet Functions 2 December 29th 04 09:57 PM


All times are GMT +1. The time now is 07:37 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"