Thats what I'm trying to do but I can't get things to work the way I
want them to.

Lets say something gets by all my validation and a bad variable makes
it to a query in a CFC method. Now I have an error. So I put a try
catch around the query to control the errors in the CFC. Since I need
the results from the CFC query, I'll get an error on the page calling
it because the page didn't receive a query. I got a thrown error
message instead. Now I need to check to see if I'm getting an error or
a query and use a few more try catches.

There has to be a better way of handling all this. I downloaded some
apps to see how the best CFers were taking care of these sort of
things and not one of them had a try catch in their code. :-| Perhaps
I'm being a little paranoid with the error handling.



On Tue, 8 Mar 2005 20:33:33 -0000, COLLIE David
<[EMAIL PROTECTED]> wrote:
> > So what is the best way to handle errors in a CFC?
> 
> Throw it?  That's what I've been doing... Then document what you will
> throw so that any calling code can catch any errors and decide what to
> do.
> 
> Hopefully I'm on track with that one :)
> 
> --
> dc
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:197901
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to