Close form without saving the data back to the table

JCtheEUC

Board Regular
Joined
Jul 17, 2008
Messages
50
I have seen this post in other threads but have not seen any real answers. If you know of one please point me in the right direction.

Issue:
I have a form in Access that user will enter information in and post it back to the table. Currently if the they hit the close button it posts the incomplete data back to the table. I don't want that to happen. Idealy if they hit the close button it would simply close and not post back.

Any help would be greatly appreciated.

Thanks!
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
I have seen this post in other threads but have not seen any real answers. If you know of one please point me in the right direction.

Issue:
I have a form in Access that user will enter information in and post it back to the table. Currently if the they hit the close button it posts the incomplete data back to the table. I don't want that to happen. Idealy if they hit the close button it would simply close and not post back.

Any help would be greatly appreciated.

Thanks!

I'm not sure how you tell if the form has been completed properly, but
Me.undo might work if they have not yet moved off the form and caused an
update.
I think your mechanism to know that complete data has been entered is a key part of this issue.


Here is a link, via a google search, that may be useful.
http://en.allexperts.com/q/Using-MS-Access-1440/Saving-Data-Form.htm
 
Last edited:
Upvote 0
Make all fields "must fill" fields and tell the enter'er on the form that if all fields are not completed no data will be saved. Also upon closing have a message box open with that message and give them the option to close the message and go back to the form.
 
Upvote 0
Use the Form's BEFORE UPDATE event and check to see if all of your controls are filled out (the ones you want for a complete record) and if not issue a

Cancel = True
Me.Undo
 
Upvote 0

Forum statistics

Threads
1,220,965
Messages
6,157,120
Members
451,399
Latest member
alchavar

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top