Adobe 38043740 - ColdFusion Standard - Mac Development Manual page 292

Developing applications
Hide thumbs Also See for 38043740 - ColdFusion Standard - Mac:
Table of Contents

Advertisement

DEVELOPING COLDFUSION 9 APPLICATIONS
Developing CFML Applications
"Error","web-13","12/19/01","11:29:07",MYAPP,"Exception error --
Exception type: coldfusion.runtime.CfErrorWrapper
Template: /MYStuff/MyDocs/exceptiontest.cfm,
Remote Address: 127.0.0.1,
HTTP Reference:
Diagnostics: Cannot find CFML template for custom tag testCase. Cannot
find CFML template for custom tag testCase. ColdFusion attempted looking
in the tree of installed custom tags but did not find a custom tag with
this name."
The text consists of a comma-delimited list of the following entries:
• Log entry type, specified by the
• ID of the thread that was executing
• Date the entry was written to the log
• Time the entry was written to the log
• Application name, as specified in the Application.cfc initialization code (by setting the This.application variable)
or by a
tag (for example, in an Application.cfm file).
cfapplication
• The message specified by the
Handling runtime exceptions with ColdFusion tags
Exceptions include any event that disrupts the normal flow of instructions in a ColdFusion page, such as failed
database operations, missing include files, or developer-specified events. Ordinarily, when ColdFusion encounters an
exception, it stops processing and displays an error message, or an error page specified by a
wide Error Handler option on the Settings page in the Administrator. However, you can use the ColdFusion exception
handling tags to catch and process runtime exceptions directly in ColdFusion pages.
This ability to handle exceptions directly in your application pages enables your application to do the following:
• Respond appropriately to specific errors within the context of the current application page
• Recover from errors whenever possible.
Exception-handling tags
ColdFusion provides the exception-handling tags listed in the following table:
Tag
Description
cftry
If any exceptions occur while processing the tag body, look for a
execute the code in the
cfcatch
Execute code in the body of this tag if the exception caused by the code in the
exception type specified in this tag's attributes.
Used in
cfthrow
Generate a user-specified exception.
cfrethrow
Exit the current
Used only in
attribute
cflogtype
attribute.
cflogtext
cfcatch
tag body.
tag bodies only.
cftry
block and generates a new exception of the same type.
cfcatch
cfcatch
tag bodies.
Last updated 1/20/2012
tag or the Site-
cferror
cfcatch
tag that handles the exception, and
tag body matches the
cftry
287

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion 9

Table of Contents