Aug 30 2022 03:26 AM
Hi everyone, I would need help, I'm new in IF function, so I would be happy of your help. How should I write IF fomula IF for:
I have one cell C14 with word HB in it and one cell with the dates and in the third cell I should write IF function so that 2 conditions would be true than it should write YES, iof both conditions are not TRUE than it should be NO in the cell, for example:
IF cell C14 = HB and M14 = DATE 27.10.2022 than YES, otherwise NO
I thought it should be
IF(AND(C14="HB", M14=datevalue("27.10.2022"), "YES", "NO"))
But this is not working.
Can somebody help me?
TNX
Aug 30 2022 03:38 AM
=IF(AND(C14="HB", M14=DATEVALUE("27.10.2022")), "YES", "NO")
You can try this formula.
Aug 30 2022 03:52 AM
@JasminajudoSLO You may try below formula.
=IF((C14="HB")*(M14=DATE(2022,10,27)), "YES", "NO")
Remember datevalue("27.10.2022") shouldn't work as "27.10.2022" couldn't be recognized as date value. In Excel dot (.) is not date separator until you manually change date separator from control panel. DATEVALUE("27-Oct-2022") should work in this way.
=IF((C14="HB")*(M14=DATEVALUE("27-Oct-2022")), "YES", "NO")
Aug 30 2022 08:02 AM