Bryan,

That’s because after looking at the code, you had the return prior to the
cactch.

This is what I always do.

<cffunction>
<cftry>
   .... Logic
 </cftry>
 <cfcatch>
   .... Catch Error
</cfcatch>
 <cfreturn retValue />
</cffunction>

Now as this was a query you could defined the retValue as an empty query,
then if the cacth is being caught it would fall through and return an empty
query. Otherwise the query will be returned populated.


Regards,
Andrew Scott
 
Quote of the Day:
Your manuscript is both good and original, but the part that is good is 
not original and the part that is original is not good.
-----Original Message-----
From: Bryan Stevenson [mailto:[EMAIL PROTECTED] 
Sent: Thursday, 13 October 2005 8:14 AM
To: CF-Talk
Subject: [Norton AntiSpam] Re: [Norton AntiSpam] SOLVED: Re: CFCs and
cftry/cfcatch

nope...the proper return bailed (intentionally so I could test the 
try/catch) casuing the cfcatch to fire off...it had no return so I still 
ended up with a method returning something not of type query

just my own stupidity...it happens...shhhhh ;-)

Bryan Stevenson B.Comm.
VP & Director of E-Commerce Development
Electric Edge Systems Group Inc.
phone: 250.480.0642
fax: 250.480.1264
cell: 250.920.8830
e-mail: [EMAIL PROTECTED]
web: www.electricedgesystems.com 




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:220867
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=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to