Jump to content
Sign in to follow this  

Clearing AutoIt.Error

Recommended Posts


In the help file it states

You can only have ONE Error Event Handler active per AutoIt script. If you are writing UDF's containing COM functions, you can check if the user has an Error Handler...If no Error Handler was active, you can temporarily install your own during the UDF call.

OK, I understand that (I think) and assign my own like this:
$oMyError = ObjEvent("AutoIt.Error","MyErrFunc") ; Install a custom error handler
But now I want to set it back to "null", "empty", default, whatever. IOW if a COM error occurs the script should generate an error and end.

How would I do that?

My Projects:DebugIt - Debug your AutoIt scripts with DebugIt!

Share this post

Link to post
Share on other sites

To clear it, empty the variable with

$oMyError = 0

GDIPlusDispose - A modified version of GDIPlus that auto disposes of its own objects before shutdown of the Dll using the same function Syntax as the original.EzMySql UDF - Use MySql Databases with autoit with syntax similar to SQLite UDF.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.