Results 1 to 2 of 2
  1. #1
    5 Star Lounger
    Join Date
    Nov 2001
    Jerusalem, Israel
    Thanked 1 Time in 1 Post

    between times (xp/2k)

    I remember a discussion here about finding overlaps of time.
    i.e. - If I have a schedule of classes that start and end at random times, not all on a specific part of the hour, and I want to know all classes going on between two other random times. I hope that is clear.
    Am I remembering correctly, because I could not find it, and if it was not discussed, does anyone have any ideas, before I try to reinvent the wheel?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: between times (xp/2k)

    Similar problems have been discussed several times.

    Say that the schedule has fields ClassStart and ClassEnd, and you want to know classes that overlap with the time period from TimeStart to TimeEnd (these could be parameters, or references to text boxes on a form).
    Set the criteria for the ClassStart field to <=[TimeEnd] and the criteria for ClassEnd to >=[TimeStart]
    (The above may be mangled, it's supposed to read "less than or equal to TimeEnd" and "greater than or equal to TineStart")

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts