Sign in to follow this  
Followers 0
eltorro

Script abnormal exit.

5 posts in this topic

#1 ·  Posted (edited)

I been fighting with this now for hours.

When part of my script includes some code as an included file, it runs as expected.

When the code from the include is pasted to the end of the script ( and the #include directive commented out) the the script crashes unexpectedly.

The include file is APIFileReadWrite.au3

This is my script. SavePrtScBMP.au3

Any Ideas ?

eltorro

Edited by eltorro

Share this post


Link to post
Share on other sites



May be a silly question, but did you bother to do any error handling in the DLL Calls? I see it in a few places (SetError(etc, etc), but no return for the errors.


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

May be a silly question, but did you bother to do any error handling in the DLL Calls? I see it in a few places (SetError(etc, etc), but no return for the errors.

There's a log file.

_BinaryFileWrite($hFile, $FileHead)
        If $DEBUG Then
            _FileWriteLog($LOG,"Error Status: "&@error &@LF)
            _FileWriteLog($LOG,"File header written" & @LF)
        EndIf

Many debug statements.

Edited by eltorro

Share this post


Link to post
Share on other sites

There's a log file.

_BinaryFileWrite($hFile, $FileHead)
        If $DEBUG Then
            _FileWriteLog($LOG,"Error Status: "&@error &@LF)
            _FileWriteLog($LOG,"File header written" & @LF)
        EndIf

Many debug statements.

Yeah, I noticed that when I looked at the regular file, I hadn't seen anything but the #include file at that point, thus my "May be" statement... I knew you liked to debug after seeing alot of your scripts.

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

I knew you liked to debug after seeing alot of your scripts.

Better safe than sorry.

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