We have a bound form that opens by default to the first of several thousand
records. We'd like the form to automatically open to a new blank record.
What code is necessary to do this?
Thanks in advance.
Mark
Rick Brandt - 19 Jul 2005 18:25 GMT
> We have a bound form that opens by default to the first of several
> thousand records. We'd like the form to automatically open to a new
[quoted text clipped - 3 lines]
>
> Mark
Use the optional acFormAdd argument if opening from code or set the
DataEntry property of the form to Yes in design view.

Signature
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
JonOfAllTrades - 30 Sep 2005 14:54 GMT
> We have a bound form that opens by default to the first of several thousand
> records. We'd like the form to automatically open to a new blank record.
[quoted text clipped - 3 lines]
>
> Mark
You can also add code such as this to your form's On_Open event, and it will
always run. You won't have to hunt down all buttons that open the form.
Private Sub Form_Open(Cancel As Integer)
DoCmd.GoToRecord , , acNewRec
End Sub
Using DataEntry hides all existing records, though this may be what you're
looking for.