Sign in to follow this  
Followers 0
Guest tempacc1

Avoid Any Error Messagbox

10 posts in this topic

I use a compiled autoit-script that will be started remote.

It's really the case that some features of the script can only be tested if the script is started remote.

A Problem arises because on the target machine a message box can not bee seen by anybody, so no interaction is possible leading to an indefinitely waiting process.

Is it possible to avoid any error message boxes created by autoit, even for syntax errors that may be left :idiot: within very rarely executed code parts.

One Solution would be to have an other script watching for a autoit message box to pop up from the first one. But I would prefer having on Opt("?") to switch the behaviour.

By the way, we do not have an Eval('code-string') in Autoit?

Share this post


Link to post
Share on other sites



It depends on what caused the msgbox. Every situation can be handled by well-written code and some pre-checking before running. You will need to search the forum for tylo's au3check which will check the entire syntax of the code before running the script. If you are getting errors while running a non-existant program, then you can use Opt("RunErrorsFatal", 0)


Who else would I be?

Share this post


Link to post
Share on other sites

It depends on what caused the msgbox. :idiot: Every situation can be handled by well-written code and some pre-checking before running. :D You will need to search the forum for tylo's au3check which will check the entire syntax of the code before running the script. If you are getting errors while running a non-existant program, then you can use Opt("RunErrorsFatal", 0)

<{POST_SNAPBACK}>

We need not discuss this, i thought about all of your suggestions before.

But to know EVERY situation in advance is never possible. In my case i have to exspect many future changes in environment for the script to run e.g. acces rights, file stucture...

So i just asks wether there is a switch to avoid the display of a message box, that in the case of my script nobody can ever see.

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

I don't know if it will work for compiled scripts but for autoit3.exe there's a switch /ErrorStdOut. I don't know if it's only in the unstable version.

Edit: Looks like it also surpresses Messageboxes on compiled scripts but does not write anything to stdout when it's compiled.

Edited by sugi

Share this post


Link to post
Share on other sites

I don't know if it will work for compiled scripts but for autoit3.exe there's a switch /ErrorStdOut. I don't know if it's only in the unstable version.

Edit: Looks like it also surpresses Messageboxes on compiled scripts but does not write anything to stdout when it's compiled.

<{POST_SNAPBACK}>

It writes to stdout, it DOES NOT write to a console window. That is virtually a technical impossibility for a Windows application to do.

Share this post


Link to post
Share on other sites

I don't know if it will work for compiled scripts but for autoit3.exe there's a switch /ErrorStdOut. I don't know if it's only in the unstable version.

Edit: Looks like it also surpresses Messageboxes on compiled scripts but does not write anything to stdout when it's compiled.

<{POST_SNAPBACK}>

Thanks, that's what i was looking for. And best, it's working in the version (3, 0, 102, 0) that i currently use.

I can not find anything about that winthin the docs. How come that You know it but not me? Where can i find these informations. May be i stumble over even greater inventions.

BTW: AutoIt is one of the best things i love to use since a long time. But whom i have to say that...

Share this post


Link to post
Share on other sites

How come that You know it but not me?

We're special.

Who else would I be?

Share this post


Link to post
Share on other sites

We're special.

<{POST_SNAPBACK}>

Ohh, You did know it too!

But would You be so kind and share Your source?

Share this post


Link to post
Share on other sites

Thanks, that's what i was looking for. And best,  it's working in the version (3, 0, 102, 0) that i currently use.

I can not find anything about that winthin the docs. How come that You know it but not me?  Where can i find these informations. May be i stumble over  even greater inventions.

BTW: AutoIt is one of the best things i love to use since a long time. But whom i have to say that...

<{POST_SNAPBACK}>

I remebered that scite does this and wrote a small one-character-script to run in scite and then checked which command line option it used.

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  
Followers 0