Suppress warning/error message "record can't be saved"

G

Guest

Hi,

I am trying to make my users exit and close the form using a button on the
form instead of using the "x" button on the form and/or Access application.

I've figured out how to do this by setting the CloseButton to "No" in the
form property, and setting/checking for Tag value in form Load, Unload, and
it's working fine except for one minor issue.

When I try to close the application using "x", I get the warning/message
that "You cannot save this record at this time. ....Do you want to close the
database object anyway?" When I click "Yes", I get the custom message that I
placed, and the user exits by clicking the button on the form.

So, I'm getting TWO message windows (one is Access-generated, one is custom)
when I try to close the application the FIRST time.

How can I suppress the Access-generated window/message? Since I don't need
it as my custom message is being displayed allright.

Thanks for any pointers.

-Amit
 
A

Andreas

I think there is an API call which enables you to disable the Access
close button - that way you can do the closing through your form/menu.

Regards,
Andreas
 
G

Guest

Andreas,

I've already figured out how to have the user exit through the button on the
form when s/he clicks the Access Application close button. I'm getting the
standard warning message followed by my custom message. So, I'd like to not
display the standard message. Your response was not quite helpful, but thanks
for trying.

-Amit
 

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