Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > microsoft.public.scripting.vbscript > #11944

Re: Is there a way to check the state of the error handler?

From "R.Wieser" <address@not.available>
Newsgroups microsoft.public.scripting.vbscript
Subject Re: Is there a way to check the state of the error handler?
Date 2018-05-16 17:36 +0200
Organization Aioe.org NNTP Server
Message-ID <pdhj6l$1pka$1@gioia.aioe.org> (permalink)
References <2tcspbxl8haf.1tz7eicrk8vcl.dlg@40tude.net> <pdeu86$1cfv$1@gioia.aioe.org> <ebmajwq4bpia.3yvh723p792x.dlg@40tude.net> <pdh1v1$qe1$1@gioia.aioe.org> <pdh8ia$8kl$1@dont-email.me>

Show all headers | View raw


Mayayana,

>  If you don't want to trust On Error Resume Next
> to clear the error

Whut?   The fact that the above command actually does clear the error value 
is something my offered method *depends* on.

However, I would have liked it if the "on error goto 0" *disabeling* of the 
error catching wouldn't reset the error object.   So an error status could 
easily be checked afterwards.

> Then you don't have to rewrite everything to test
> for -1,

Re-read the subject line please.   Initializing the error number to 
something else than the default zero value enables the OP to detect if an 
error handler/catcher was invoked at some point (which is not exactly what 
the OP asked, but seems to be good enough for him).

> and you don't have to worry that an unsupported use may, at some point, 
> fail.

What makes you think its unsupported ?     And why/how do you think it 
worries me ?    It didn't even cross my mind.

The only thing that happened there is that I (re?)learned something: I'm 
allowed to change the error value (and possibly the description and other 
properties too) to whatever I want.   Which could be usefull.

Regards,
Rudy Wieser

Back to microsoft.public.scripting.vbscript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Is there a way to check the state of the error handler? JJ <jj4public@vfemail.net> - 2018-05-15 13:04 +0700
  Re: Is there a way to check the state of the error handler? "Auric__" <not.my.real@email.address> - 2018-05-15 06:55 +0000
    Re: Is there a way to check the state of the error handler? JJ <jj4public@vfemail.net> - 2018-05-15 22:10 +0700
  Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-15 09:14 -0400
    Re: Is there a way to check the state of the error handler? JJ <jj4public@vfemail.net> - 2018-05-15 22:22 +0700
      Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-15 11:53 -0400
  Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-15 17:26 +0200
    Re: Is there a way to check the state of the error handler? JJ <jj4public@vfemail.net> - 2018-05-16 16:52 +0700
      Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-16 12:42 +0200
        Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-16 08:34 -0400
          Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-16 17:36 +0200
            Re: Is there a way to check the state of the error handler? JJ <jj4public@vfemail.net> - 2018-05-19 00:03 +0700
              Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-18 13:18 -0400
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-18 20:15 +0200
                Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-18 15:12 -0400
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-19 11:23 +0200
                Re: Is there a way to check the state of the error handler? "Mayayana" <mayayana@invalid.nospam> - 2018-05-19 10:28 -0400
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-19 22:19 +0200
              Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-18 20:06 +0200
                Re: Is there a way to check the state of the error handler? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2018-05-18 23:27 +0200
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-19 12:15 +0200
                Re: Is there a way to check the state of the error handler? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2018-05-19 21:30 +0200
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-19 22:21 +0200
                Re: Is there a way to check the state of the error handler? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2018-05-19 22:32 +0200
                Re: Is there a way to check the state of the error handler? "R.Wieser" <address@not.available> - 2018-05-20 11:06 +0200
                Re: Is there a way to check the state of the error handler? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2018-05-20 12:09 +0200

csiph-web