Hi All,
I have a generic function I use to validate if a value is within a drop down list. I recently decided to make it error within the function rather than passing it back to the calling proc, and I decided to do this by raising a custom error. This works as expected the first time it is invoked, but second and subsequent times produce an Automation error on the err.raise line. The complete sequence of events are:
1. user presses "Validate" button to start validation code
2. A user entered value fails the lookup and the expected error msgbox in the error handler is displayed
3. Usr clicks OK in msgbox and validation ends
4. User corrects the error (or not) and then again presses the validate button
5. Either the same value or another value fails the lookup function, but this time a "Run-time error '-2147220503 (800403e9)' Automation error is thrown
6. pressing debg takes me to the err.raise line
Full procedure shown below - Any advice welcome
![]()
Please Login or Register to view this content.
Bookmarks