Results 1 to 7 of 7
  1. #1
    2 Star Lounger
    Join Date
    Apr 2008
    Posts
    188
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Add record action (2002)

    I have added a button to a form to add a new record. That works, but when I start to add data to the fields in the new record, I can add the first field and when I push Tab to go to the next field the cursor jumps down to that field in another new record.

    Any idea why that is happening?

    Thanks.

    Paul

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

    Re: Add record action (2002)

    Do you have any event procedures for that control?

  3. #3
    2 Star Lounger
    Join Date
    Apr 2008
    Posts
    188
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Add record action (2002)

    Yes one in the after update property. When I removed it things worked.

    Me.MaxNumber = MaxNumber I was trying to populate a field automatically.

    Is there another way to do that.

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

    Re: Add record action (2002)

    Could you post a stripped down copy of your database? See <post#=401925>post 401925</post#> for instructions.

  5. #5
    2 Star Lounger
    Join Date
    Apr 2008
    Posts
    188
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Add record action (2002)

    I figured out the after update issue but now I have a new question. When I open the form the first field is a textbox which is good to view the existing data. When I add a new record it would be better if the grade field is a combo box attached to the grade query. But if I use a combo box when I tab to the next field the cursor jumps to a new record again. Any ideas?

    File attached

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

    Re: Add record action (2002)

    The easiest way is to right-click the Grade text box and select Convert To | Combo Box, then set the Row Source of the combo box to qryGrades.
    If you delete the text box and add a combo box, the new combo box will be the last control in the tab order. Select View | Tab Order and move the Grade combo box to the top of the list.

  7. #7
    2 Star Lounger
    Join Date
    Apr 2008
    Posts
    188
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Add record action (2002)

    Thanks Hans. That works.

    I think I as making it too complicated.

    Paul

Posting Permissions

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