Sign in to follow this  
Followers 0
cdnnewbie

how to check if script runs successfully or not

5 posts in this topic

I have anti virus deployment script that runs at 2 different sites and I would like to confirm that it ran successfully or not.

Is their anyway to do this.


[quote]He who smiles in a crisis has found someone to blame[/quote]

Share this post


Link to post
Share on other sites



Check and use exit codes.

Also you can create log files.

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

You can create log files heres an example:

FileWriteLine($log1, " Blah Blah Blah was initiated at - " & @HOUR & ":" & @MIN & ":" & @SEC & @LF);

I think thats right. I'm new at this, but I think that is how you would do it from what I have seen.

Edited by HelloIDistance

Share this post


Link to post
Share on other sites

FileWriteLine($log1, " Blah Blah Blah was initiated at - " & @HOUR & ":" & @MIN & ":" & @SEC & @LF)

Looks good, but no semicolon at the end (since AutoIt doesn't require it.) Also, a lot of applications that people might use to read logs (like notepad.exe) won't properly display the @LF char. You should probably either use @CRLF, or leave it blank. Remember that with FileWriteLine, it will add @CRLF if you don't have either of them on the end.

[font="Optima"]"Standing in the rain, twisted and insane, we are holding onto nothing.Feeling every breath, holding no regrets, we're still looking out for something."[/font]Note: my projects are off-line until I can spend more time to make them compatable with syntax changes.

Share this post


Link to post
Share on other sites

You can create log files heres an example:

FileWriteLine($log1, " Blah Blah Blah was initiated at - " & @HOUR & ":" & @MIN & ":" & @SEC & @LF);

I think thats right. I'm new at this, but I think that is how you would do it from what I have seen.

there's a handy _FileWriteLog in one of the files in the include folder, I think it's file.au3... check it out.

"I'm not even supposed to be here today!" -Dante (Hicks)

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