SOLVED

New Contributor

# If formula with multiple conditions

Hello

How do I do an if formula with multiple conditions. I think what I am looking for would be an If And formula but I am struggling to work out how to do it.

I currently have =IF(B1='Haulier Log'!C3,'Haulier Log'!C4,"")

B1 = tomorrow's date

Haulier log C3 = A date

Haulier log C4 = text

I want the info from C4 to to automatically be shown if B1 and Haulier Log C3 are the same. This currently works with the formula I have but I then have an issue when I want to insert multiple conditions, as I need the same to happen for each day of the month.

5 Replies

# Re: If formula with multiple conditions

You can probably use one of the lookup functions, but we need details about your setup. Could you attach a sample workbook without sensitive information?

# Re: If formula with multiple conditions

=HLOOKUP(B2,'Haulier log'!\$C\$3:\$J\$4,2,FALSE)

I understand your return data in sheet "Haulier log" is in horizontal order as shown in the attached file. Maybe the above formula is what you are looking for.

# Re: If formula with multiple conditions

Thank you, I have attached a copy.

I want the formula to go into column E on the tabs named the days of the week.

So really when the date in the haulier log matches the day I am planning, I want the info to be populated.

Thanks

best response confirmed by Sergei Baklan (MVP)
Solution

# Re: If formula with multiple conditions

In E3:

=INDEX('Haulier Log'!\$C\$4:\$AG\$16,MATCH(\$A3,'Haulier Log'!\$A\$4:\$A\$16,0),MATCH(\$B\$1,'Haulier Log'!\$C\$3:\$AG\$3,0))

Fill down.

See the attached version.

I changed the dates in row 3 of the Haulier Log sheet to dates in this month (you had dates in January of 2022), and entered fake data below.

# Re: If formula with multiple conditions

Thank you very much!!