In this case, I believe you do need to use evaluate (unless you are on
MX!). However, your code will use N evaluates, where N is the rowcount.
You can get around this by doing one:
<cfset theQuery = evaluate("caller.#attributes.query#")>
Then your code gets MUCH easier:
<cfoutput query="theQuery">
<option value="#theQuery[attributes.value][currentRow]#" etc
=======================================================================
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: Sam Farmer [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, August 01, 2002 5:48 PM
> To: CF-Talk
> Subject: Calling Queries
>
>
> Hi,
>
> I am trying to rewrite an old custom tag of ours that takes
> in a query and
> outputs it with right options selected. Nothing too
> tricky...except that I
> can not work out how to get around using evaluate.
>
> Anyone got any pointers?
>
> This is the code:
>
> <cfoutput query="caller.#attributes.query#">
> <option value="#evaluate("#attributes.value#")#" <cfif
> listfind(attributes.selected,evaluate("#attributes.value#"))>S
> ELECTED</cfif>
> >#evaluate("#attributes.display#")#
> </cfoutput>
>
> Thanks,
>
> Sam
>
>
>
>
>
______________________________________________________________________
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