> why can't I do this????? i mean, I need to do this!!
> because i have to put over 3,000 names!!!! How can I
> loop over a "write" CFFILE tag? because it would keep
> making new files. why can't i put it all in one single
> thing? I was also thinking putting all that info in one
> variable, but how do I specify a line break in that
> variable? that line break is important, because Access
> reads it as a new row. grrrrrr!!!
>
> output="<CFOUTPUT query="hello">#fname#,#lname#
> </CFOUTPUT>"
You can't use CFOUTPUT there, because you can't use it in any CF tags - it's
only intended to output CFML expressions into HTML or other text returned
directly to the browser (although you can also use it to loop over a
recordset without actually generating any output, if you like. But don't
freak out, Mr. Bear! You can still do what you want, by building a single
variable:
<cfset mystr = "">
<cfset CrLf = Chr(13) & Chr(10)>
<cfoutput query="hello">
<cfset mystr = mystr & fname & "," & lname & CrLf>
</cfoutput>
<cffile action="write" output="#mystr#" ...>
Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.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