mIRC Home    About    Download    Register    News    Help

Print Thread
#73890 05/03/04 06:59 PM
Joined: Dec 2002
Posts: 56
Babel fish
OP Offline
Babel fish
Joined: Dec 2002
Posts: 56
I think this is not a very useful function.
For every alias in my script I will have to put a :erro and $error doesn´t give me the file name or the line were the error occurred.

The smartest thing you could do is add an error event, like:
on *:scripterror: {
echo -s Error found: $error
}

This would be usefull for people that have their scripts on the net and when an error occurs the users don´t know what to say because they cleared the text or there mirc closed down, and just say that something went wrong. With this, there could be an erro log created and the user would just send them the file.

smile

#73891 05/03/04 10:02 PM
Joined: Dec 2002
Posts: 2,962
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
I think the best thing to do would be add an error event aswell, and have them it triggered just 'above' the default error-handling. So when an error occurred it would go through these steps:
current alias' error jump-point code.
propagate through calling aliases' error-handling code.
call script error event(s).
mIRC's default error-handling code.


And of course allow /reseterror to halt the error-handling at any point. This way you can have alias-specific handling and/or generic handling.

Really this thread should be in Feature Suggestions though, since whether you like $error or not, you can't consider it a bug.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
#73892 06/03/04 08:15 AM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
there is a easy solution to your wooes



Just dont have your code error.



<snicker snicker>


Link Copied to Clipboard