Empty Record on Form Open

K

KsFireworksGal

Is there a way to have the cursor default to an empty records when you open a
form? I have a form I use for data entry of inventory - right now it opens
to the first record, and sometimes I get in a hurry and start typing my new
product without using the buttons to go to the end of the records to get a
blank to start typing in.

I am using ACCESS 2000

Lynette
 
K

KARL DEWEY

If you set the Data Entry property to Yes it can only be used for data entry
and will open to a blank new record.
 
L

Linq Adams via AccessMonster.com

As KARL said, setting the Data Entry property to Yes will open to a blank
record, but you can ONLY add new records in that mode; you cannot view
existing records. If you want to do both, use this, with Data Entry property
to No:

Private Sub Form_Load()
DoCmd.GoToRecord , , acNewRec
End Sub
 
D

debmdb

I'm a 'newbie' with creating my own Access 2003 databases, in the past I've
always used wizards...so...is there another way to view and enter records
without going into the VBA?
 
L

Linq Adams via AccessMonster.com

No. If you ever plan to really do any developing in Access you need start
using VBA. In this case it's not really that complicated. In your form's
Design View, goto

View - Code

This will bring to the code window behind your form. At the top of the code
window you'll see an Option statement, something like:

Option Compare Database

Now paste in the code I gave you, directly below that:

Private Sub Form_Load()
DoCmd.GoToRecord , , acNewRec
End Sub

Now, to return to Design View, click on the red Access "key" icon on the
toolbar.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top