Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    May 2003
    Location
    Manchester, Gtr Manchester, England
    Posts
    552
    Thanks
    0
    Thanked 0 Times in 0 Posts

    record order (2000)

    Hello, is there a way on a one to many form that the records in the subform can be displayed with the most recent records and new record first? I have quite a number of entries making funcitonality that little bit more awkward when having to scroll down.

    Many thanks Darren.

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

    Re: record order (2000)

    It is not possible to make Access show the blank new record as first record in a form. It is always at the end, past the existing records.
    You can change the record source of the subform so that it is sorted descending on a suitable date field (assuming you have such a field).
    Another possibility is to put code in the On Current event of the main form:

    Private Sub Form_Current()
    On Error Resume Next
    Me.[SubformName].SetFocus
    RunCommand acCmdRecordsGoToNew
    ' Optional - select a control on the main form
    Me.[SomeControl].SetFocus
    End Sub

    Here, SubformName is the name of the subform as a control on the main form, and SomeControl is the name of a control on the main form you want to select (optional).

  3. #3
    4 Star Lounger
    Join Date
    May 2003
    Location
    Manchester, Gtr Manchester, England
    Posts
    552
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: record order (2000)

    Thanks Hans, that's spot on.

    Darren.

Posting Permissions

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