I have a problem with users closing a form with SOME information entered into fields, so I put the following code in to remove any record currently being written:
On Error GoTo Err_Command38_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, acUndo, , acMenuVer70
The problem is that it pops up a box asking if I really want to delete the record. I'm afraid this might confuse the users who don't realize that the incomplete information they have entered is a record (since they didn't hit the button I made to insert the current record). Is there some code that I could put in to make it automatically select YES on the pop-up (so that it doesn't come up at all)?
On Error GoTo Err_Command38_Click
DoCmd.DoMenuItem acFormBar, acEditMenu, acUndo, , acMenuVer70
The problem is that it pops up a box asking if I really want to delete the record. I'm afraid this might confuse the users who don't realize that the incomplete information they have entered is a record (since they didn't hit the button I made to insert the current record). Is there some code that I could put in to make it automatically select YES on the pop-up (so that it doesn't come up at all)?