2 if statement in one cell

kelvin_9

Active Member
Joined
Mar 6, 2015
Messages
259
=IF(OR(C51="*",C51=""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"RDO",""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"wrong",C51))

=IF(C51="00:00 - 00:00",VLOOKUP($A51,'SCHEDULE-1'!$A:$I,3,FALSE),"")

can this 2 if statement be used in one cell like cell D51?

thanks in advance
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

DanteAmor

Well-known Member
Joined
Dec 3, 2018
Messages
12,622
Office Version
  1. 2007
Platform
  1. Windows
Try this

=IF(OR(C51="*",C51=""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"RDO",""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"wrong",IF(C51="00:00 - 00:00",VLOOKUP($A51,'SCHEDULE-1'!$A:$I,3,FALSE),C51)))
 

snjpverma

Well-known Member
Joined
Oct 2, 2008
Messages
1,384
Office Version
  1. 2016
Platform
  1. Windows
I am guessing what does the first part of the formula does? I believe it's giving a "yes" if is some data in cell due to asterisk ( * ) and also giving a yes if it is blank due to the quotes ( "" )..
Let me know the concept if I am thinking wrong.

OR(C51="*",C51="")
 

kelvin_9

Active Member
Joined
Mar 6, 2015
Messages
259
Try this

=IF(OR(C51="*",C51=""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"RDO",""),IF(ISNUMBER(MATCH(C$49,INDEX(RDO!$A$2:$M$100,,MATCH('RESULT-1'!$B51,RDO!$A$1:$M$1,0)),0)),"wrong",IF(C51="00:00 - 00:00",VLOOKUP($A51,'SCHEDULE-1'!$A:$I,3,FALSE),C51)))
thank you so much for the prompt reply
Its working just prefect
All master here are saving my life like jesus:love:
 

kelvin_9

Active Member
Joined
Mar 6, 2015
Messages
259
I am guessing what does the first part of the formula does? I believe it's giving a "yes" if is some data in cell due to asterisk ( * ) and also giving a yes if it is blank due to the quotes ( "" )..
Let me know the concept if I am thinking wrong.

OR(C51="*",C51="")
the formula I am using is to return
When blank cell, it might employee’s RDO(rotation day off) with a table and if their criteria(RDO# & date) are met
you may refer to another post here, you will find what I am talking then:biggrin:

 

DanteAmor

Well-known Member
Joined
Dec 3, 2018
Messages
12,622
Office Version
  1. 2007
Platform
  1. Windows
Im glad to help you , thanks for the feedback.
 

Watch MrExcel Video

Forum statistics

Threads
1,130,030
Messages
5,639,635
Members
417,101
Latest member
amoverton2

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
Top