Solved

Execution error

Posted on 2014-04-13
5
281 Views
Last Modified: 2014-04-16
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
Comment
Question by:DatabaseDek
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 84

Assisted Solution

by:Scott McDaniel (Microsoft Access MVP - EE MVE )
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 250 total points
ID: 39997839
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
 

Author Comment

by:DatabaseDek
ID: 39998469
I will do that and respond

Thank you
0
 
LVL 50

Accepted Solution

by:
Gustav Brock earned 250 total points
ID: 40000957
Change the END to Exit Sub or Exit Function.

/gustav
0
 

Author Comment

by:DatabaseDek
ID: 40001404
I got around it by using Cancel event. Is that OK? seems to work
0
 
LVL 50

Expert Comment

by:Gustav Brock
ID: 40001448
If it works why not.

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

/gustav
0

Featured Post

Independent Software Vendors: 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!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question