On Mar 5, 10:01 pm, StephenL <[email protected]> wrote:
> In my migration from CFMX 7 to Open BD, I'm encountering a difficult
> problem. Despite much effort, I don't seem to be able to get cferror
> to "handle" all exceptions. In CFMX 7, I could use this code:
Where is your error handler? Application.cfm? OnRequest/end?
controller.cfm?
Is it possible that the error handler is in a controller architecture,
but the data error is coming from an api outside of that controller?
I find it suspicious that only certain types of errors are not
handled. I know it worked in a different engine, but is it possible
theres something in your architecture that is the root cause?
Also, heres a snippet from a reliable error handler I've written...
<CFSet allScopes =
StructKeyList( getPageContext().getBuiltInScopes() ) >
<CFSet allScopes= ListSort( allScopes,"textnocase","asc","," ) >
<CFOUTPUT>
<CFLoop list="#AllScopes#" index="OneScope">
<CFSet y = evaluate("#OneScope#")>
<hr size="4" width="100%" noshade="true" /><br />
<H1>#OneScope# Collection</h1><br />
<ul>
<CFSet GotOne = false>
<CFLOOP COLLECTION="#y#" ITEM="Key">
<CFIF IsSimpleValue( y[Key] )>
<cfif key neq "PASSWORD" and key neq "HTTP_COOKIE">
<li><B>#Key#</B> - #y[Key]#</li>
<CFSet GotOne = true>
</cfif>
<CFELSEIF IsArray(y[Key])>
<li><B>#Key#</B>
<OL>
<CFLOOP INDEX="i" FROM="1"
TO="#ArrayLen(y[Key])#">
<LI>
<CFSet y = structsort(y,"textnocase")>
<CFLOOP COLLECTION="#y[Key] [i]#"
ITEM="Key2">
<B>#key2#</B> - #y[Key] [i][Key2]#
<CFSet GotOne = true>
</CFLOOP>
</CFLOOP>
</OL>
</li>
</CFIF>
</CFLOOP>
<cfif not GotOne>[ No Vars ]</cfif>
</ul><br /><br />
</cfloop>
</CFOUTPUT>
--
Open BlueDragon Public Mailing List
http://www.openbluedragon.org/ http://twitter.com/OpenBlueDragon
mailing list - http://groups.google.com/group/openbd?hl=en
!! save a network - please trim replies before posting !!