But it defaults to yes - so if he wants to just copy them over, he can
leave it off. :)

Of course, there is something to be said about including optional args
just as a helpful reminder about what's going on. :)

=======================================================================
Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc
Member of Team Macromedia

Email    : [EMAIL PROTECTED]
Blog     : www.camdenfamily.com/morpheus/blog
Yahoo IM : morpheus

"My ally is the Force, and a powerful ally it is." - Yoda 

> -----Original Message-----
> From: Barney Boisvert [mailto:[EMAIL PROTECTED] 
> Sent: Monday, March 03, 2003 1:22 PM
> To: CF-Talk
> Subject: RE: dynamically created session variables
> 
> 
> Make sure you add a third parameter to structAppend() for 
> whether or not you want to overwrite values.  And note that 
> it'll add EVERYTHING in the FORM scope, which may or may not 
> be what you want.
> 
> > -----Original Message-----
> > From: Raymond Camden [mailto:[EMAIL PROTECTED]
> > Sent: Monday, March 03, 2003 11:18 AM
> > To: CF-Talk
> > Subject: RE: dynamically created session variables
> >
> >
> > Or even better:
> >
> > <cfset session[fieldname] = form[fieldname]>
> >
> > No need for evaluate, or all those #s and "s.
> >
> > You can also do:
> >
> > <cfset structAppend(session,form)>
> >
> > 
> ======================================================================
> > =
> > Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc
> > Member of Team Macromedia
> >
> > Email    : [EMAIL PROTECTED]
> > Blog     : www.camdenfamily.com/morpheus/blog
> > Yahoo IM : morpheus
> >
> > "My ally is the Force, and a powerful ally it is." - Yoda
> >
> > > -----Original Message-----
> > > From: Ben Doom [mailto:[EMAIL PROTECTED]
> > > Sent: Monday, March 03, 2003 1:03 PM
> > > To: CF-Talk
> > > Subject: RE: dynamically created session variables
> > >
> > >
> > > IIRC, you need to do
> > >
> > > <cfset session["#fieldname#"] = evaluate("fieldname")>
> > >
> > >
> > > --  Ben Doom
> > >     Programmer & General Lackey
> > >     Moonbow Software, Inc
> > >
> > > : -----Original Message-----
> > > : From: Ali Daniali [mailto:[EMAIL PROTECTED]
> > > : Sent: Monday, March 03, 2003 1:48 PM
> > > : To: CF-Talk
> > > : Subject: dynamically created session variables
> > > :
> > > :
> > > : I'm trying to load form variables into session variables in an
> > > : application...but I'm having problems with the creating
> > > : dynamically created
> > > : session variable names. Any help is appreciated.
> > > :
> > > : <CFLOOP index="FieldName" list="#Form.FieldNames#">
> > > :         <CFLOCK TIMEOUT="30"  THROWONTIMEOUT="No" 
> TYPE="EXCLUSIVE"
> > > : SCOPE="SESSION">
> > > :                 <CFSET Session.&"#FieldName#" = 
> "#Evaluate(FieldName)#">
> > > :         </CFLOCK>
> > > : </CFLOOP>
> > > :
> > > : Thanks,
> > > : Ali
> > > :
> > > : -------------------------------------------------------
> > > : This message (including any attachments) may contain
> > > : confidential and privileged information.  If you are
> > > : not the intended recipient, please notify the sender
> > > : and delete all copies of the original message without
> > > : using or disclosing it.  Thank you.
> > > : -------------------------------------------------------
> > > :
> > > :
> > > :
> > > :
> > >
> > 
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to