Cfthrow - MACROMEDIA COLDFUSION 4.5-CFML LANGUAGE Reference

Cfml language reference
Table of Contents

Advertisement

218

CFTHROW

The CFTHROW tag raises a developer-specified exception that can be caught with
CFCATCH tag having any of the following type specifications:
CFCATCH TYPE= "custom_type "
CFCATCH TYPE= "APPLICATION "
CFCATCH TYPE= "ANY "
Syntax
<CFTHROW
TYPE= "exception_type "
MESSAGE="message"
DETAIL= "detail_description "
ERRORCODE= "error_code "
EXTENDEDINFO= "additional_information ">
TYPE
Optional. A custom type or the predefined type APPLICATION. None of the other
predefined types should be specified because these types are not generated by
ColdFusion applications. If you specify the exception type APPLICATION, you
need not specify a type for CFCATCH, because the APPLICATION type is the
default CFCATCH type.
MESSAGE
Optional. A message that describes the exceptional event.
DETAIL
Optional. A detailed description of the event. The ColdFusion server appends the
position of the error to this description; the server uses this parameter if an error is
not caught by your code.
ERRORCODE
Optional. A custom error code that you supply.
EXTENDEDINFO
Optional. A custom error code that you supply.
Usage
Use CFTHROW within a
can access any accompanying information as follows:
Message with CFCATCH.message
Detail with CFCATCH.detail
Error code with CFCATCH.errorcode.
To get additional information, use CFCATCH.TagContext. TagContext captures
the context of the exception; that is, the name and position of each tag in the
tag stack, and the full path names of the files that contain the tags in the tag
stack.
CFTRY
block to raise an error condition.The CFCATCH block
CFML Language Reference

Advertisement

Table of Contents
loading
Need help?

Need help?

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

Questions and answers

This manual is also suitable for:

Coldfusion 4.5

Table of Contents