IF OR Statement

JTL9161

Well-known Member
Joined
Aug 29, 2012
Messages
567
Office Version
  1. 365
Platform
  1. Windows
Having trouble with (I think is) a IF OR statement.

I have a name in 3 different columns.

John is in B3, H3 and N3
If a date is entered in C3 I want the names in H3 and N3 to disappear.
If a date is entered in I3 I want the names in B3 and N3 to disappear.
If a date is entered in O3 I want the names in B3 and H3 to disappear.

I can get the first argument to work but not the 2nd.

Thanks in advance for your help.

James
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
You will need to supply a lot more information than that. ;)
 
Upvote 0
Im having trouble trying to find your question :)

Basically it is:

=IF(OR(A1="Hello", B1="Bye"), TRUE, FALSE)
 
Upvote 0
Updated. I hit entered before finishing the text
 
Upvote 0
Are B3, H3 & N3 where you want to enter the formula?
 
Upvote 0
Yes. All 3 cells B3, H3 and N3 have "John" in them. Only want 1 name showing. If date is in C3 then John in B3 and remove from H3 and N3, If date in I3 then John in H3 and remove from B3 and N3...and I think you get it if there's a date in O3.

thanks
 
Upvote 0
A formula can only affect the cell it is in, so if B3,H3 & N3 are hard values, then you cannot "remove" them with a formula in another cell.
 
Upvote 0
A formula can only affect the cell it is in, so if B3,H3 & N3 are hard values, then you cannot "remove" them with a formula in another cell.
So i cannot have a if statement in B3 saying if I3 or O3 does not equal "" then no name in B3, IF I3 and O3 equal "" (blank) then "John" and I put this in B3, H3 and N3. Basically saying if C, I or O are blank then "John" if any contain a date then other 2 should be blank with no 'John" in them I'd put the formula in all 3 columns and change the IF's to the other 2 columns. I'm probably not explaining this as I am thinking it.
 
Upvote 0
You can put a formula into those cells to display John or "" is that what you are trying to do?
 
Upvote 0
Yes. Let me try to water this down. Formula in 3 columns B, H, N. When I put the formula in 1 of the 3 columns (B,H,N) if any of the other 2 columns have a date then blank out other 2 columns. I tried this in cell C3 but its not working

=IF(I3,OR(O3="","John",""))
 
Upvote 0

Forum statistics

Threads
1,214,829
Messages
6,121,827
Members
449,051
Latest member
excelquestion515

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top