Hi Amber,
it sounds like you want the form to go a new record when it is opened
put this code in the [Event Procedure] for the form LOAD event:
'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Private Sub Form_Load()
If Not Me.NewRecord Then
DoCmd.RunCommand acCmdRecordsGoToNew
End If
End Sub
'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If the user doesn't type anything, the new record will not be saved
Warm Regards,
Crystal
remote programming and training
Access Basics
8-part free tutorial that covers essentials in Access
http://www.AccessMVP.com/strive4peace
*
have an awesome day
*
No, I don't want to delete any of the information in the table.
What I want to accomplish is...when the user exits the main form to go back
to the switchboard, then opens the main form again...I want all of the
controls to be null on form load. From there the user will decide whether to
search for a record or enter a new record. I don't want the last record
viewed to still be visible on form load.
Thanks,
Amber
:
On Tue, 15 Jul 2008 12:34:00 -0700, abrown wrote:
I'm sure the code is very simple, but I'm having trouble figuring it out. I
have a main form (which is bound to a table) that opens when selected from
the main switchboard. I want this form to open with all fields cleared;
however, since all of the fields are bound to the table the form opens with
the record I last viewed. How can I get the form to open with all controls
cleared even though they are bound to a table?
Thanks,
Amber
Clearing the bound controls when a form opens will delete the data in
the first record in the table.
I don't think that is what you wish to do.
So... instead of asking How, why not tell us What (you wish to
accomplish).