Validation on date

J

jk

I need to have a validation between two date columns so if the date is
greater than 90 days, it can either stop the user or flag the user.Can this
be done?
 
P

Peo Sjoblom

One day is 1 in Excel so you can use validation>allow>date or allow>custom
where you refer to a fixed date in a cell like

=A1>90+$B$2

where A1 is the cell that you validate and B2 the date

--


Regards,

Peo Sjoblom

Excel 95 - Excel 2007
Northwest Excel Solutions
www.nwexcelsolutions.com
(remove ^^ from email)
 
M

MSweetG222

On the toolbar, go to Data | Validation while you are on the cell containing
date the User is entering (in my example, cell B1). Select "Custom". In the
Formula box type:

=IF(B1-A1>90,1=2,1=1)

Where B1 = the cell the user is data entering
Where A1 = the existing date

The formula is say if the date (in B1) is more than 90 days from the date
(in A1) then 1=2 (which is false and will give the user an error message).
If the date in B1 is less than the date in A1 then 1=1 (which is true & no
error message given to user). Play around with it to make it fit your
situation. Also, look at the other tabs, you can customize the error
message, etc.

See also:
http://www.contextures.com/xlDataVal01.html

Thx
MSweetG222
 
J

jk

I must be doing something wrong Could you explain if i used cell A8 AND B8 to
produce an error message if the date difference is greater than 90 days.This
is the formula to use???
 
Top