You might want to try something like this: <cfcomponent> <cfset variables.ncid = 0> <!--- called when CFC is created ---> <cffunction name="checkNCID" access="public" output="false"> <cfargument name="NCID" required="no" default="#variables.ncid#"> <cfset var id = 0 /><!--- var the ID so it is local to this method ---> <cfif arguments.NCID NEQ 0 AND len(argument.NCID)> <cfset id = arguments.NCID /> </cfif> <cfreturn ID /> </cffunction> </cfcomponent>
Calling Page: <cfinvoke component="NCSelected" method="checkNCID" returnvariable="id"> <cfinvokeargument name="NCID" value="#ncid#" /> </cfinvoke> HTH, Rich Kroll ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Create robust enterprise, web RIAs. Upgrade & integrate Adobe Coldfusion MX7 with Flex 2 http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:263121 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4