Results 1 to 4 of 4
  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Which event? (2003)

    When my form displays a record, there are five ways to move from the currently displayed record; there are control buttons for Previous Record, Next Record and New Record, there is a control button to close the form and save the data and finally, there is a combo box from which the user can select another employee and a combobox after-update event moves to the selected record.
    I need to know when the DB is moving to a different record regardless of which option the user has used; is there a single 'best event' to use to trap this, or do I have to write VB for each option path?
    Thanks
    Silverback
    Silverback

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

    Re: Which event? (2003)

    The On Current event of the form occurs whenever the user moves to a record, whether interactively or through code.
    There is no event that always occurs when the user moves away from a record, including when the form is closed.

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Which event? (2003)

    Hmmm; bit of a blow, that. However, as always, the info is valuable in that it stops me trying to implement something that isn't going to work.
    Just to be clear : if I am displaying record1 and I move to record2, and I trap the On Current event, if I refer to Me.LastName in the event procedure, it will refer to LastName in record2. Is that correct?
    Thanks
    Silverback
    Silverback

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

    Re: Which event? (2003)

    > if I am displaying record1 and I move to record2, and I trap the On Current event, if I refer to Me.LastName in the event procedure, it will refer to LastName in record2.

    Yes, that is correct. On Current occurs for the record you are moving TO, not for the record you are moving FROM.

Posting Permissions

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