Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Keep Pop-Up Data Entry Form Blank

Status
Not open for further replies.

TOTCOM11

Programmer
Aug 5, 2003
199
0
0
US
I am currently working on a customer contact database for my company. I have a "Add New Contact" command button on my form that pops up a subform when the user wants to add new contact to the current contact list. The data entry property on this form is set to true as well as the "Allow Additions" property. If I click this button right after the main form loads, everything works correctly. However, when I click this button after I have selected a new customer, a contact's information which was previously entered for that company appears in the new pop up subform.

How can I make sure that the data entry subform is blank every time I click the command button?

TOTCOM11
 
set the text property for each control to ""


txtFirstName.Text = ""
txtLastName.text = ""

etc.
 
You need to open the sub form using acNewRecord as a parameter, using DoCmd if I recall correctly. (I'm not on my Access development PC so I can't lookup the correct syntax)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top