Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Apr 2001
    Location
    New York, New York, USA
    Posts
    170
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Trigger an event (XP)

    Hello, I have created a clock in my database that works fine. What I am now trying to do is to have an event (print a report) occur when the clock reaches a certain time (2 AM). Any ideas?

  2. #2
    Platinum Lounger
    Join Date
    Feb 2002
    Location
    A Magic Forest in Deepest, Darkest Kent
    Posts
    5,681
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Trigger an event (XP)

    Couple of questions before start:

    1) Will the database be open all the time?
    2) If not what do you want to happen if I open the database at 2.01am?
    3) Is it a "clock" that is a control on a form
    4) Could you use the system clock as your "Clock"
    Jerry

  3. #3
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trigger an event (XP)

    Are you using the On Timer event of the form?
    I would create a table with one date/time field. Enter today's date manually.
    Let the On Timer event compare the current date to the date in the table. If (a) the current date is later than the date in the table and ([img]/forums/images/smilies/cool.gif[/img] the current time is 2 AM or later then
    (1) Print the report
    (2) Set the date in the table to the current date.

Posting Permissions

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