Controls disappear

B

Bumbino

All of my controls disappear when I set the "Allow Additions" property to NO.
I want the user to be able to enter data and when they are sure they want to
save, I will code the Allow Additions property to Yes and then save the data.
 
J

Jeanette Cunningham

Set the Data Entry property to Yes to make the form go to a new blank
record. Users enter the data in the controls and you let them save the data
when they either the form or move to the next new record.

Jeanette Cunningham
 
L

Linq Adams via AccessMonster.com

Controls "disappearing" is normal behavior when

"Allow Additions" is set to NO

and

there are no records in the underlying recordsource

"I want the user to be able to enter data and when they are sure they want
to save, I will code the Allow Additions property to Yes and then save the
data."

You can't do this in Access with a bound form. You could have an unbound form,
allow the user to enter data and then decide whether to write it to your
table, but this requires a lot of work that's really unnecessary to
accomplish your goal.

The best way to address your problem would be to

Have a bound form

Have AllowAdditions set to YES

Have code in the Form_BeforeUpdate event that asks the user if they want to
save the record

Either dump the record (Me.Undo) or Save the record

Jeanette's suggestion of setting the Data Entry property to Yes to make the
form go to a new blank record will ***only allow you to enter new records***;
you can't then use the form to view existing records, which sounds like your
goal.
 

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