# I need help with a formula!!

#### Transporter

##### New Member
I'm in charge of the transportation department for a community clinic, and am creating a workbook that tracks the mileage on the vans we use. I want to include a formula that will alert me when a van has passed a certain mileage.

The only formula I am aware of is "=IF(A1=mileage, "x". "")"

The problem is that I want it to apply to this setup:

-Date- -Start- -End-
1/1/09 44,000 44,100
.
.
.
1/31/09

As I understand it, I need a formula that uses a matrix in order to track the "Start" and "End" miles for all 31 days.

Any ideas?

### Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a \$25,000 loan, 5% annual interest, 60 month loan.

#### rfinkels

##### New Member
There are a few ways to do what you are doing.

If you want a formula then something along the lines of (where maxvalue is your mileage you wish to be alerted at):
Code:
``=IF(OR(B2>maxvalue,C2>maxvalue),"Mileage exceeded","")``
put this into a fourth column and it will show you "mileage exceeded" in the fourth row at the point (and actually every day after) you reach the maxvalue

The second choice is using conditional formatting.

Select the cell go to Format -> Conditional formatting
Then select "Cell Value is" and "less than" and put in the mileage you wish to be alerted at. Then set the format to have a red background. This will make all the cells red after the point where you have excceded the set mileage.

Hope that helped.

Replies
1
Views
2K
Replies
6
Views
469
Replies
1
Views
201
Replies
7
Views
194
Replies
13
Views
628

1,191,374
Messages
5,986,274
Members
440,016
Latest member
vasanrajeswaran

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