Subforms in MS Access

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sue dukes
    New Member
    • May 2010
    • 1

    Subforms in MS Access

    Hello. I have reversed a notes field in a subform so that the latest notes appear at the top. I wish to have the 'new field' available at the top, rather than at the foot of the list which is defaul. Can anyone suggest a way of achieving this. Many thanks. Sue
  • Stewart Ross
    Recognized Expert Moderator Specialist
    • Feb 2008
    • 2545

    #2
    Sorry, Sue, but Access does not allow the reversal of the way it presents its rows to users, so there is no way I know of that you can have Access's blank data entry row appearing first.

    I place a set of my own navigation buttons for the subform on the main form, and include a button marked New to take the user directly to the next new record for entry without scrolling to the bottom of the list or using the subform navigation buttons to do so. It's not the solution you seek, but it works within the limitations of how Access displays datasheet and continuous-view forms.

    If you were using a continuous-view form as your subform you could place an unbound textbox into your form header and use that for new notes, as it will always be placed before the detail rows that follow it. You would need to handle the insertion of a new note yourself in code though, by running an 'Insert Into [YourTable] ...' SQL statement generated in code from the After Update event of the textbox. You would also need to requery your subform control to show the new record just inserted, and clear the unbound textbox contents ready for the user to insert another note.

    This approach would not work with datasheet-view subforms, as these are data-only views which do not show additional controls that are placed on the underlying form.

    -Stewart

    Comment

    Working...