[cfaussie] Catching cfcomponent extends errors

2011-06-07 Thread AJ Dyka
Hi All,

I've done some searching and haven't found any answers yet so I
figured I'd throw the question out here and see what comes back :)

I have an Application.cfc in an app which I want to extend another
which is accessed via a mapping like so:

cfcomponent output=false extends=mapping.ParentApplication

My issue is when the mapping doesn't exist it fails which is fine but
I want to catch the error and handle it rather than just dump the
error to the screen.

I can't try/catch around the outside of the component and onError
doesn't get invoked because the Application can't be initialised so I
think I'm stuck ... any ideas?

Thanks.

A.J.

-- 
You received this message because you are subscribed to the Google Groups 
cfaussie group.
To post to this group, send email to cfaussie@googlegroups.com.
To unsubscribe from this group, send email to 
cfaussie+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en.



Re: [cfaussie] Catching cfcomponent extends errors

2011-06-07 Thread Kai Koenig
Have you tried putting cferror tags in various places, for instance 
onApplicationStart or so?

Cheers
Kai

 
 
 I've done some searching and haven't found any answers yet so I
 figured I'd throw the question out here and see what comes back :)
 
 I have an Application.cfc in an app which I want to extend another
 which is accessed via a mapping like so:
 
 cfcomponent output=false extends=mapping.ParentApplication
 
 My issue is when the mapping doesn't exist it fails which is fine but
 I want to catch the error and handle it rather than just dump the
 error to the screen.
 
 I can't try/catch around the outside of the component and onError
 doesn't get invoked because the Application can't be initialised so I
 think I'm stuck ... any ideas?






-- 
You received this message because you are subscribed to the Google Groups 
cfaussie group.
To post to this group, send email to cfaussie@googlegroups.com.
To unsubscribe from this group, send email to 
cfaussie+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en.



Re: [cfaussie] Catching cfcomponent extends errors

2011-06-07 Thread Mark Mandel
cferror ?

Go old school :D

Mark

On Wed, Jun 8, 2011 at 10:07 AM, AJ Dyka ajd...@learnosity.com wrote:

 Hi All,

 I've done some searching and haven't found any answers yet so I
 figured I'd throw the question out here and see what comes back :)

 I have an Application.cfc in an app which I want to extend another
 which is accessed via a mapping like so:

 cfcomponent output=false extends=mapping.ParentApplication

 My issue is when the mapping doesn't exist it fails which is fine but
 I want to catch the error and handle it rather than just dump the
 error to the screen.

 I can't try/catch around the outside of the component and onError
 doesn't get invoked because the Application can't be initialised so I
 think I'm stuck ... any ideas?

 Thanks.

 A.J.

 --
 You received this message because you are subscribed to the Google Groups
 cfaussie group.
 To post to this group, send email to cfaussie@googlegroups.com.
 To unsubscribe from this group, send email to
 cfaussie+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/cfaussie?hl=en.




-- 
E: mark.man...@gmail.com
T: http://www.twitter.com/neurotic
W: www.compoundtheory.com

cf.Objective(ANZ) - Nov 17, 18 - Melbourne Australia
http://www.cfobjective.com.au

Hands-on ColdFusion ORM Training
www.ColdFusionOrmTraining.com

-- 
You received this message because you are subscribed to the Google Groups 
cfaussie group.
To post to this group, send email to cfaussie@googlegroups.com.
To unsubscribe from this group, send email to 
cfaussie+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en.



Re: [cfaussie] Catching cfcomponent extends errors

2011-06-07 Thread Sean Corfield
This is a *compile-time* error so no code is executing at the time the
compiler hits that error. It's why you cannot use per-application
mappings here - it's the very first piece of code the compiler sees
and until it has compiled it, there's no code to run - and therefore
nothing executed that can possibly trap the error.

In other words, you cannot catch this error.

On Tue, Jun 7, 2011 at 5:07 PM, AJ Dyka ajd...@learnosity.com wrote:
 I've done some searching and haven't found any answers yet so I
 figured I'd throw the question out here and see what comes back :)

 I have an Application.cfc in an app which I want to extend another
 which is accessed via a mapping like so:

 cfcomponent output=false extends=mapping.ParentApplication

 My issue is when the mapping doesn't exist it fails which is fine but
 I want to catch the error and handle it rather than just dump the
 error to the screen.

-- 
You received this message because you are subscribed to the Google Groups 
cfaussie group.
To post to this group, send email to cfaussie@googlegroups.com.
To unsubscribe from this group, send email to 
cfaussie+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en.