http://qs321.pair.com?node_id=143304


in reply to Trapping Error Object

I think that what you want is eval BLOCK but all this is a little vague.

You would do something like:

eval { # do something that might raise a fatal error }; if ( $@ ) { # do something to report the error # $@ contains the error message or error object }

However it might be useful if you gave us a bit more of a clue as to what it was you were trying to do.

/J\