Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #30613
| Path | csiph.com!1.us.feeder.erje.net!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder1.news.weretis.net!news.solani.org!.POSTED!not-for-mail |
|---|---|
| From | "Christoph M. Becker" <cmbecker69@arcor.de> |
| Newsgroups | comp.lang.javascript |
| Subject | Re: try ... catch for a specific error ? |
| Date | Thu, 2 Jun 2016 14:40:03 +0200 |
| Organization | solani.org |
| Lines | 22 |
| Message-ID | <nip9et$h5d$1@solani.org> (permalink) |
| References | <574fe5c6$0$5901$e4fe514c@news.xs4all.nl> <nip2aa$lvc$1@solani.org> <5750271d$0$5837$e4fe514c@news.xs4all.nl> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=utf-8 |
| Content-Transfer-Encoding | 7bit |
| X-Trace | solani.org 1464871197 17581 eJwFwYkBwEAEBMCWvItyxNF/CZlxBWPC4DA/v5a7NQvXx8m2TwTc8pXO44pNSLbI9XgrZkMzUXyd/lEeE8XVzjY5vtreV02zY1WeOvUDkioemw== (2 Jun 2016 12:39:57 GMT) |
| X-Complaints-To | abuse@news.solani.org |
| NNTP-Posting-Date | Thu, 2 Jun 2016 12:39:57 +0000 (UTC) |
| User-Agent | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 |
| X-User-ID | eJwFwYEBACAEBMCVCv80DtH+I3QH5eZ1I2h4eBMjS4ISJabK9HXF0VE61SYz1siY5Nl9gh8OkhDd |
| In-Reply-To | <5750271d$0$5837$e4fe514c@news.xs4all.nl> |
| Cancel-Lock | sha1:esnhkApgv0OmCzamWAEQhTS/Jb8= |
| X-NNTP-Posting-Host | eJwNyckBAzEIA8CWuAR2OdYC/ZeQzHfgqflVJDKwWDVZfS5lCiumyVSXts4FP5NXR5gb97XSNhwGP0YkeiOvMql2B7LJHvxLAJlH56ngD0XFHUU= |
| Xref | csiph.com comp.lang.javascript:30613 |
Show key headers only | View raw
On 02.06.2016 at 14:32, R.Wieser wrote: >> You can do something like: > ... >> throw ex; > > Thanks, I was not aware that I could re-throw the origional error like that. > > But that leaves my a) question: how do I compare the, in my case being the > NS_ERROR_NOT_AVAILABLE error-constant, to the returned "ex" object ? > Documentation as provided by > https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Obj > ects/Error does not mention such a property ... Most likely for a good reason: this error constant appears to be highly user-agent specific. I would try my best to avoid messing with such a constant, and indeed concentrate on the root cause: why is something (what?) not available in the first place? -- Christoph M. Becker
Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 09:54 +0200
Re: try ... catch for a specific error ? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2016-06-02 11:21 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 12:18 +0200
Re: try ... catch for a specific error ? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2016-06-02 13:22 +0200
Re: try ... catch for a specific error ? "Christoph M. Becker" <cmbecker69@arcor.de> - 2016-06-02 12:38 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 14:32 +0200
Re: try ... catch for a specific error ? "Christoph M. Becker" <cmbecker69@arcor.de> - 2016-06-02 14:40 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 15:40 +0200
Re: try ... catch for a specific error ? "Christoph M. Becker" <cmbecker69@arcor.de> - 2016-06-02 16:03 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 16:23 +0200
Re: try ... catch for a specific error ? "Christoph M. Becker" <cmbecker69@arcor.de> - 2016-06-02 16:43 +0200
Re: try ... catch for a specific error ? Tim Streater <timstreater@greenbee.net> - 2016-06-02 20:42 +0100
Re: try ... catch for a specific error ? Tim Streater <timstreater@greenbee.net> - 2016-06-02 20:44 +0100
Re: try ... catch for a specific error ? JJ <jj4public@vfemail.net> - 2016-06-02 20:24 +0700
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-02 16:35 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-03 10:50 +0200
Re: try ... catch for a specific error ? "Christoph M. Becker" <cmbecker69@arcor.de> - 2016-06-03 17:35 +0200
Re: try ... catch for a specific error ? "R.Wieser" <address@not.available> - 2016-06-03 22:25 +0200
Re: try ... catch for a specific error ? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2016-06-03 23:55 +0200
csiph-web