Sure, just do:
<cfset res = evaluate("valuelist(query.#itemid#)")>
FYI - this is one of the FEW times you need Evaluate.
FYI2 - A UDF for this was written by one of my coworkers and will be up
on CFLib.org soon.
=======================================================================
Raymond Camden, ColdFusion Jedi Master for Macromedia
Email : [EMAIL PROTECTED]
Yahoo IM : morpheus
"My ally is the Force, and a powerful ally it is." - Yoda
> -----Original Message-----
> From: Michael Dinowitz [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, July 10, 2002 12:01 PM
> To: CF-Talk
> Subject: dynamic valuelist
>
>
> The ValueList() function takes as its attribute the name of a
> query field. This is passed in without quotes (essentially
> breaking the rule of non-quoted variables inside functions
> being evaluated). What I want to do is create a UDF and pass
> in a query and the name of a column. These are to be combined
> within a ValueList() to be evaluated.
>
> var Items = ValueList(evaluate('Query.'&ItemID));
>
> This fails. Does anyone have a suggestion as to how I can
> create the attribute for the valuelist dynamically or should
> I just run a loop (which is just a few milliseconds slower).
>
> Michael Dinowitz
> Master of the House of Fusion
> http://www.houseoffusion.com
>
>
______________________________________________________________________
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists