|
-
Jun 4th, 2009, 03:31 PM
#26
Re: When NOT to use Structured Exception Handling
@Pradeep: I'd still be using an If statement, because the cost of an exception is too high to be desirable if there is ANY other option.
@TG: The only way I can see Re-Try working would be if there were no function calls in the block. You can come up with plenty of more plausible examples, but in the situation that I described, with A->B->C->D, what would happen if B showed a form prior to calling C? The catch block would see the error as being the call to B, so I would expect a re-try to re-show the form, which could get ugly. Thus, the only place I think the re-try could start would be at the line of code in D that raised the exception.
Worse, if D trapped exceptions and re-threw them, what would a Re-try mean for an exception handler in A? Does it restart at the point in D where the exception was thrown?
I can barely remember how On Error Goto worked, but I seem to remember that it didn't propagate errors back out of the sub it was in. It should be the same as A retrying the call to B, with all the problems that could create.
My usual boring signature: Nothing
 
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|