Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here


Run-Time error '2109':

Run-Time error '2109':

Run-Time error '2109':

Help... On my form i have a button that does several things...
1). Saves the record
2). Prints the current record
3). Advances to the next new (blank) form (record)
4). Places the cursor at the field named ETR as the starting point for the next new record.

Often times but not every time I get an error message that
Run-Time error '2109'
There is no field named 'ETR' in the current record.

I then have an option to END or DEBUG,
When I click DEBUG the code that is highlighted is:
DoCmd.GoToControl "ETR"

I DO clearly have a field named ETR in both the table and form.

My entire code for this button is as follows:

Private Sub Command23_Click()

    DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
    DoCmd.PrintOut acSelection
    DoCmd.GoToRecord , , acNewRec
    DoCmd.GoToControl "ETR"

    Exit Sub

End Sub

Is something wron or missing???
I am using Access 97 on Windows 98

Thanks again,

RE: Run-Time error '2109':

Try this....

Instead of-

DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
DoCmd.PrintOut acSelection
DoCmd.GoToRecord , , acNewRec
DoCmd.GoToControl "ETR"

DoCmd.Save acForm, "YourFormName"
DoCmd.PrintOut acSelection
DoCmd.GoToRecord , , acNewRec

Hope this helps.

RE: Run-Time error '2109':

you can also just set the tab order of the form so that ETR is the first field, then it will always go there and you dont have to write any code for it.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close