Glad it works! I'm no expert on the mechanics but basically pre-MX you have to define the item as a structure first before u can start adding keys to it...
Stace -----Original Message----- From: Smith, Matthew P -CONT(DYN) [mailto:[EMAIL PROTECTED]] Sent: Wednesday, November 27, 2002 12:52 PM To: CF-Talk Subject: RE: can't reference #attributes# on cf5? Wouldn't setting a variable in the attributes scope cause it to be defined? Here's a bit more expanded view of the code: <cfif variables.errorsFound> <cfset attributes.ssn = form.ssn> <cfset attributes.lastName = form.lastName> <cfset attributes.birthDateYear = form.birthDateYear> <cfset attributes.birthDateMonth = form.birthDateMonth> <cfset attributes.birthDateDay = form.birthDateDay> <cfmodule template="login.cfm" errorslist="#variables.errorsList#" attributeCollection="#attributes#"> <cfabort> </cfif> It errors out on the attributeCollection="#attributes#", line above the cfabort. I added in you snippet, and it's working now. Thanks so much. I'm just curious as to why setting a var wouldn't create the structure? <cfif variables.errorsFound> <cfif NOT IsDefined("attributes")> <cfset attributes = structNew()> </cfif> <cfset attributes.ssn = form.ssn> <cfset attributes.lastName = form.lastName> <cfset attributes.birthDateYear = form.birthDateYear> <cfset attributes.birthDateMonth = form.birthDateMonth> <cfset attributes.birthDateDay = form.birthDateDay> <cfmodule template="login.cfm" errorslist="#variables.errorsList#" attributeCollection="#attributes#"> <cfabort> </cfif> >>-----Original Message----- >>From: Stacy Young [mailto:[EMAIL PROTECTED]] >>Sent: Wednesday, November 27, 2002 11:41 AM >>To: CF-Talk >>Subject: RE: can't refernce #attributes# on cf5? >> >>Perhaps the attribute struct is not yet created when that line of code >>executes. That may cause the error in CF5...and in MX it would auto create >>the struct if it didn't exist. >> >><cfif NOT IsDefined("attributes")> >> <cfset attributes = structNew()> >></cfif> >> >>HTH >> >>Stace >> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com

