Nice one, works well.
So does this, which a firiend suggested:

<cfset thisvar="level" & v & "id">
<cfparam name="#thisvar#" default="">


----- Original Message -----
From: "BORKMAN Lee" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, December 28, 2000 10:22 PM
Subject: RE: "Creating" Variables?


> Hi Richard,
>
> I'd go for this:
>
> <CFPARAM NAME="variable#v#" DEFAULT="">
>
> You can use isDefined("variable#v#") to check for the existence of the
> variable if you don't want to set a default value.
>
> Lee (Bjork) Borkman
> http://bjork.net ColdFusion Tags by Bjork
>
>
> -----Original Message-----
> From: Richard Gilbert [mailto:[EMAIL PROTECTED]]
>
>
> What I am trying to figure out at the moment is how to create a variable
> dynamically, then test for its existence!
>
> For example, I am starting with a simple index loop:
> <cfloop index="v" from="2" to="6">
>
> Then, at the start of each loop, I need to do a cfparam for a
corresponding
> variable.
> That is, at the beginning of the first loop I need to do:
> <cfparam name="variable2" default="">
>
> At the beginning of the second loop I need to do:
> <cfparam name="variable3" default="">
>
> ....
>
>
> IMPORTANT NOTICE:
> This e-mail and any attachment to it is intended only to be read or used
by
> the named addressee.  It is confidential and may contain legally
privileged
> information.  No confidentiality or privilege is waived or lost by any
> mistaken transmission to you.  If you receive this e-mail in error, please
> immediately delete it from your system and notify the sender.  You must
not
> disclose, copy or use any part of this e-mail if you are not the intended
> recipient.  The RTA is not responsible for any unauthorised alterations to
> this e-mail or attachment to it.
>
>
~~~~~~~~~~~~~ Paid Sponsorship ~~~~~~~~~~~~~
Get Your Own Dedicated Win2K Server!      Instant Activation for $99/month w/Free 
Setup from SoloServer      PIII600 / 128 MB RAM / 20 GB HD / 24/7/365 Tech Support     
 Visit SoloServer, https://secure.irides.com/clientsetup.cfm.

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to