G
Guest
Here is something that is really bothering me to the point I cannot sleep.
I have a form that on one of the command buttons the code is basically:
DoCmd.RunSQL "UPDATE table01...........;"
DoCmd.RunSQL "UPDATE table02...........;"
DoCmd.RunSQL "Delete * FROM table01 WHERE...........;"
DoCmd.RunSQL "UPDATE table04...........;"
DoCmd.RunSQL "UPDATE table05...........;"
This takes about 45 seconds to complete. To help protect things ; I think I
turned off the "Escape" key by catching it in the KeyDown: If KeyCode = 27
then KeyCode = 0. I think this is working. I have tried to jam it in a
practice mdb and it keeps processing to the end.
But what it one of my users who likes to make trouble hits the Ctrl-Break.
Then it will break the code and that user says "Wow, this is not a very good
system that cant control that" ; ie making more trouble. It is an .mde file
so they cannot get into the code but it still breaks and causes inconsistent
data.
It is really bothering me. In Excel all you have to say in the Sub is:
Application.EnableCancelKey = xlDisabled
Application.OnKey "^{Break}", ""
and you are protected throughout that Sub.
How is this handled in Access?
Thank you for your help.
Sleepless in the Access World
I have a form that on one of the command buttons the code is basically:
DoCmd.RunSQL "UPDATE table01...........;"
DoCmd.RunSQL "UPDATE table02...........;"
DoCmd.RunSQL "Delete * FROM table01 WHERE...........;"
DoCmd.RunSQL "UPDATE table04...........;"
DoCmd.RunSQL "UPDATE table05...........;"
This takes about 45 seconds to complete. To help protect things ; I think I
turned off the "Escape" key by catching it in the KeyDown: If KeyCode = 27
then KeyCode = 0. I think this is working. I have tried to jam it in a
practice mdb and it keeps processing to the end.
But what it one of my users who likes to make trouble hits the Ctrl-Break.
Then it will break the code and that user says "Wow, this is not a very good
system that cant control that" ; ie making more trouble. It is an .mde file
so they cannot get into the code but it still breaks and causes inconsistent
data.
It is really bothering me. In Excel all you have to say in the Sub is:
Application.EnableCancelKey = xlDisabled
Application.OnKey "^{Break}", ""
and you are protected throughout that Sub.
How is this handled in Access?
Thank you for your help.
Sleepless in the Access World