Full Version: Open form to new record
UtterAccess Discussion Forums > Microsoft® Access > Access Forms
vbnetman
Good morning,
In the db window I'm opening a form but I need to open it to a new rocord. Is there a line of code I can place in the OnLoad event that accomplishes this?

Thank you
fkegley
The simplest way to do this is to set the Data Entry property of the form to Yes in Design View.
Alan_G
If you're opening the form directly from the db window, just set the Data Entry property of the form to Yes.....
freakazeud
Hi,
if you want to be able to browse through old records then use this on the on load event:

DoCmd.GoToRecord , , acNewRec

HTH
Good luck
vbnetman
Frank and Alan, thank you. Yes I'm opening directly form the db window.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.