Thanks, Josh. That makes perfect sense now. However, I *do* wish they had come up with a different name for the scope exclusive to CFC's! Maybe something "varcomponent" or something. Anything besides the name of a scope already in use elsewhere!
Thanks for straightening me out. Rick > -----Original Message----- > From: Josh Nathanson [mailto:[EMAIL PROTECTED] > Sent: Saturday, June 21, 2008 1:14 PM > To: CF-Talk > Subject: Re: Clarification Required Concerning CFC... > > Rick - in the CFC function, variables.DSN refers to the variables scope > within the CFC only. So, you are setting the variables.DSN value, in the > instance of the object you're creating, to the value that is passed in as an > argument, arguments.DSN. > > The variables scope within a CFC is local to that CFC, and cannot be > accessed from outside it. Thus, any use of the variables scope from your > calling page, will be entirely separate from any use of the variables scope > within the CFC. This is why you have to pass in values to your CFC via > arguments, so that the CFC variable values (the "object instance" values > more specifically) can be set in the init function of the CFC. > > This is quite different than the use of cfinclude -- it's a whole different > way of thinking about things so it takes a while to wrap your mind around > it. > > -- Josh > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:307914 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

