Types Of Recoverable Exceptions Supported - MACROMEDIA COLDFUSION 4.5-DEVELOPING WEB Develop Manual

Developing web applications with coldfusion
Table of Contents

Advertisement

Chapter 8: Debugging and Error Handling
Note
<CFTRY>
... Add code here ...
<CFCATCH TYPE=" exception type 1">
... Add exception processing code here ...
</CFCATCH>
<CFCATCH TYPE=" exception type 2">
... Add exception processing code here ...
</CFCATCH>
<CFCATCH TYPE="Any">
... Add exception processing code here ...
</CFCATCH>
</CFTRY>
To catch errors in a single problematic SQL statement, for example, you might narrow
the focus by using a CFTRY block with a CFCATCH TYPE="Database" tag, outputting
the CFCATCH.State information as well.
Note
See the CFML Language Reference for information on the CFTRY, CFCATCH,
CFRETHROW, and CFTHROW tags.

Types of recoverable exceptions supported

ColdFusion Server supports several types of recoverable exceptions. Use the TYPE
attribute in the CFCATCH tag to determine which type of exception to catch.
For cases when the error handler is not able to successfully handle the
thrown error, use the CFRETHROW tag within a <CFCATCH> block.
Do not attempt to enclose an entire application in a CFTRY block by
putting the CFTRY tag in Application.cfm because you can't be sure that
there will be a matching CFTRY end tag.
95

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the COLDFUSION 4.5-DEVELOPING WEB and is the answer not in the manual?

This manual is also suitable for:

Coldfusion 4.5

Table of Contents