I have updated the link in the Script in Action Link section.
Perhaps a more detailed description might be better.

Ron

eka wrote:
Hello :)

In my opensource framework you can use a log model and catch the errors with
it.

1 - Vegas page project : http://code.google.com/p/vegas/

2 - Install my framework :
http://code.google.com/p/vegas/wiki/InstallVEGASwithSVN

3 - My framework use an event model based on the W3C DOM2/3 event model like
AS3 event model.

http://code.google.com/p/vegas/wiki/VegasTutorialsEvents

4 - My log model use a polymorphisme with the mx.logging.* package in the
Flex SDK but you can use my library in AS2, AS3, SSAS, Javascript.

http://svn1.cvsdude.com/osflash/vegas/AS2/trunk/src/vegas/logging/

5 - To catch the errors i use my vegas.errors.* package :
http://svn1.cvsdude.com/osflash/vegas/AS2/trunk/src/vegas/errors/
This package contains the abstract class AbstractError, with this class you
can creates your customs exceptions.

6 - You can try the example in the repository of the project to understand
the mecanism of my library :

- Errors :
http://svn1.cvsdude.com/osflash/vegas/AS2/trunk/bin/test/vegas/errors/
- Logging :
http://svn1.cvsdude.com/osflash/vegas/AS2/trunk/bin/test/vegas/logging/

PS : my log model use internal or external targets to dispatch the logs of the application.. you can find in my SVN repository the FlashInspector and
the SOS consoles :
http://svn1.cvsdude.com/osflash/vegas/AS2/trunk/tools/

EKA+ :)


2007/7/14, Hans Wichman <[EMAIL PROTECTED]>:

Hi,
yes I have set up some kind of global mechanism for AS2.

You can find it here
http://www.objectpainters.com/downloads/globalerrorhandler.zip

I will post information about it soon, look here for some basic info
http://objectpainters.com/blog/?p=32

Basically, its a simple RuntimeException that extends Error, so you still
can do 'throw new RuntimeException (...)'
You can subclass that as well for your own error types, an example is
included for Assert and AssertionFailedException.

What this class does is, you throw it, and you have to catch it and
consume
it (check the included example).
If you do not consume the error, a default error handler (your global
error
handler) will be called.

So even if you throw an error from an asynchronous call (eg the parse
method
of an xml callback) it will still be shown if you dont handle it.

HTH,
JC




On 7/14/07, dcamp <[EMAIL PROTECTED]> wrote:
>
> I was trying to figure out if there is a way to set up a global error
> handler.  This would catch all errors that will occur in a program.  I
> have tried putting the entry point in a try...catch block and also add
> listeners to the stage, but I am not able to handle reference errors.
>
> If anyone has attempted this or has an insight please let me know.
>
> _______________________________________________
> Flashcoders@chattyfig.figleaf.com
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to