Never seen that with 7 and now 8 and do that type of thing all the time. If this is just 6, id say upgrade. Your right, it shouldn't happen.
Regards Dale Fraser http://learncf.com -----Original Message----- From: Michael Nguyen [mailto:[EMAIL PROTECTED] Sent: Tuesday, 16 October 2007 2:25 PM To: CF-Talk Subject: Problem with using variables scope Hi People, I have encountered a very weird error with variables scope. <cfset var AnnouncementBean = createObject("component","mypath.announcement").init(argumentcollection=argu ments)/> and <cfset var AnnouncementType = createObject("component","mypath.announcementType").init(argumentcollection= arguments)/> Then I dump those two objects and found that the AnnouncementBean object is the same as AnnouncementType (it has properties and methods of AnnouncementType ) When I comment the creation of the second object then dump it, it show the correct object. I found that because <cfset variables.instance = StructNew() /> is declared in both objects and when I created the second object, this variables.instance overrides the first variables.instance was created in the first one. To me, it's really really weird as the variables scope exists only within that object. Using CFMX 7 is ok, the CF6 causes this problem. I am running in Unix. Any help is appreciated. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Get the answers you are looking for on the ColdFusion Labs Forum direct from active programmers and developers. http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid-72&catid=648 Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:291170 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

