# Conditional Formatting with Formula

#### Seba Robles

##### Board Regular
Hello all,

I'm trying to add a conditional format to a range of cells that contain number values.

The conditional format should check if the numbers on those ranges are a multiple of a number located in another fixed cell. (See screenshot example below)

Using the screenshot as reference, the multiplier or factor is located in cell B3, the cells ranging from E3:I6 are the ones that should contain the conditional format. The number in the range that are not a multiple of 10 would get highlighted.

I can't seem to figure it out, any help is greatly appreciated!!

### Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.

#### MARK858

##### MrExcel MVP
Maybe...

Book2
BCDEFGHI
310612201710
4401314718
5142301518
6202414121
Sheet2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
E3:I6Expression=MOD(E3,\$B\$3)<>0textNO

#### Mustafa Evans

##### New Member
I would try the following where E4 is in the active cell.

Excel Formula:
``=NOT(MOD(E4,\$B\$4))=0``

Drag the formula to cover the requested range.

Last edited by a moderator:

#### Seba Robles

##### Board Regular

Thank you both! Mark's response is what I was looking for, although Mustafa's does the thing, only in reverse. It highlights those that meet the pallet size, instead of the ones that don't.

#### MARK858

##### MrExcel MVP
Thank you both! Mark's response is what I was looking for,

You're welcome, btw I think @Mustafa Evans meant
Excel Formula:
``=NOT(MOD(E3,\$B\$3)=0)``
but there still is no need for the use of 2 functions.

Replies
2
Views
417
Replies
1
Views
101
Replies
5
Views
39
Replies
5
Views
165
Replies
8
Views
213

1,129,549
Messages
5,636,944
Members
416,953
Latest member
prakashkumar

### 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.

### Which adblocker are you using?

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

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