How do you make a time range criteria

L

lab

Is there a way to do a time range similiar to a date range using a field that
contains times but not dates? So the field will include times such as
8:10:00 am. I want to create a new field that includes ranges for ex., 8-10
am.
 
L

Larry G.

Are you trying to search for the times in a query? If so you can just add the
parameter to the query the same as a Date parameter: Between [Enter Start
Time] and [Enter End Time] if the field is formatted as a time already it
will pull the times between your entries.

Do you also have a field that is a date? Because the above query will pull
ALL of the times that match the parameter from within the table regardless of
the date those times occur in. To prevent add a parameter in the date field
for the date you wish your data to come from.
 
M

mnature

For your Date/Time field, set:
Format at Medium Time
Input Mask at 00:00;0;_
Validation Rule at >= #8:00:00 AM# And <= #10:00:00 AM#

This will only allow time to be entered, and only between the two times set
in the validation rule.
 
Top