Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 288
  • Last Modified:

Execution error

Hi All

Another weird one from me.

I have an on delete procedure that if a condition is not met runs to END. Which is the only way I know to stop a procedure continuing. It works in the MDB and MDE but not when run under access runtime.

When run under access runtime I get "The execution of this application has stopped due to a runtime error" and then the only option is to shuts down

anybody got a clue why?
0
DatabaseDek
Asked:
DatabaseDek
  • 2
  • 2
2 Solutions
 
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
You'd have to show us the code. Generally something like that is caused by an unhandled error so first thing to do is add error handling to your procedure.
0
 
DatabaseDekAuthor Commented:
I will do that and respond

Thank you
0
 
Gustav BrockCIOCommented:
Change the END to Exit Sub or Exit Function.

/gustav
0
 
DatabaseDekAuthor Commented:
I got around it by using Cancel event. Is that OK? seems to work
0
 
Gustav BrockCIOCommented:
If it works why not.

But what do you expect? You haven't revealed a single line of code.

/gustav
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now