# Format cell based on two values

#### Orangeanorak

##### Board Regular
Hi grateful if you can provide a formula for the following to format a cell based on two different values

=IF(G4 equals 6 or zero,"enter words","")

### Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest

#### Nine Zero

##### Well-known Member
=IF(OR(G4=6,G4=0),"enter words,"")

#### Orangeanorak

##### Board Regular
=IF(OR(G4=6,G4=0),"enter words,"")

Sorry I need to change this a bit - theres a third criteria

If Q2>1 and G4=6,G4=0,"enter words,""

#### Orangeanorak

##### Board Regular
Sorry I need to change this a bit - theres a third criteria

If Q2>1 and G4=6 or G4=0,"enter words,""

.

#### Nine Zero

##### Well-known Member
sorry just now seeing this ...

yeah no problem just add it in the or statement

=IF(AND(Q2>1,OR(G4=6,G4=0)),"enter words,"")

Replies
3
Views
181
Replies
7
Views
55
Replies
3
Views
64
Replies
5
Views
54
Legacy 456155
L
Replies
3
Views
75