Jump to content
Sign in to follow this  
cjconstantine

DOS Errorlevel codes

Recommended Posts

cjconstantine

I've been using RunWait with PSExec for remote updates (using the -d switch ... don't wait for app to exit). After seeing dozens of exit codes and not knowing whether they were errors I did a little searching, found a list of ErrorLevel codes for WinNT and slapped them into a UDF. Hope it's useful to someone (aside from me) :)

_ErrorCodes.au3

Share this post


Link to post
Share on other sites
cjconstantine

40 view, 26 downloads, and not a single comment? :)

Share this post


Link to post
Share on other sites
Zedna

40 view, 26 downloads, and not a single comment? :)

Try to use GetLastError and FormatMessage Win API

here is link

It should show you the same informations.

EDIT:

This is also better because it returns localized system error message :)

Try this:

Opt("RunErrorsFatal", 0)
Run('calc2.exe')
If @error Then MsgBox(16, "Error", "Run() produced and error:" & @CRLF & _GetLastErrorMessage ())
Edited by Zedna

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  

×