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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Subform problem

Status
Not open for further replies.

aageorge

Technical User
Jun 28, 2003
51
US
I have a form that opens up a subform based on a selection on the main form. The fields in the subform are automatically filled in based on a value in the main form. The user can change the values on the subform or just accept the default values. I have a problem, if the user just wants the default values, access won't allow him to add the record. He has to change something manually on the form before he is allowed to enter the record. How can I solve this problem?
 
Access shows always a record with default values (even if you specify default values in the table properties) tha looks like a new record. But thi is not a new inserted record so you can't save changes.
You should simulate the menu item "records/add" and then save it or you can put on the submask a button with a code like:

me.x=me.x

If x is a control filled with defaults, the code does not change his value but put the record in the state "inserted not saved".
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top