Wouldn't StructKeyExists(form,"userID") be faster --Instead of isDefined? ..
"This e-mail is from Reed Exhibitions (Gateway House, 28 The Quadrant, Richmond, Surrey, TW9 1DN, United Kingdom), a division of Reed Business, Registered in England, Number 678540. It contains information which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s) please note that any form of distribution, copying or use of this communication or the information in it is strictly prohibited and may be unlawful. If you have received this communication in error please return it to the sender or call our switchboard on +44 (0) 20 89107910. The opinions expressed within this communication are not necessarily those expressed by Reed Exhibitions." Visit our website at http://www.reedexpo.com -----Original Message----- From: Jonathon Stierman To: CF-Talk Sent: Sat Jun 02 20:03:02 2007 Subject: RE: cfinvoke or CreateObject And dynamic arguments. <cfinvoke method="getAllUsers"> <cfif isDefined("form.userID")> <cfinvokeargument name="userID" value="#form.userID#" /> </cfif> </cfinvoke> You'd have to branch out every single combination of possible parameters using just a CreateObject call. <cfif isDefined("form.userID")> <cfset recordSet = myUserCFC.getAllUsers(userID=form.userID) /> <cfelse> <cfset recordSet = myUserCFC.getAllUsers() /> </cfif> Jonathon -----Original Message----- From: Doug Bezona [mailto:[EMAIL PROTECTED] Sent: Thursday, May 31, 2007 3:07 PM To: CF-Talk Subject: Re: cfinvoke or CreateObject > > I personally can't think of any reason to use cfinvoke to call a > method of an already instantiated object. Dynamic method names ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Upgrade to Adobe ColdFusion MX7 The most significant release in over 10 years. Upgrade & see new features. http://www.adobe.com/products/coldfusion?sdid=RVJR Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:279910 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

