Perfect, thanks! This is exactly what I was looking for. Still haven't totally got used to Cold Fusion yet. I was using Tang (Witango), and the file write action didn't require additional formatting because it doesn't use ## symbols.
Rick -----Original Message----- From: Robert Harrison [mailto:rob...@austin-williams.com] Sent: Thursday, October 21, 2010 11:33 AM To: cf-talk Subject: RE: Writing cfml content to an html file Break this down into steps. 1. Get you code and queries correct to the can generate output to the screen 2. Then move that code inside a savecontent tag and write the content to a variable <cfcontent reset="true"><cfsavecontent variable="my_variable_name">MY CODE TO MAKE THE OUTPUT HERE</cfsavecontent> 3. Then write the variable content to a file: <cffile action="write" file="MYPATH\MYFILENAME" output="# my_variable_name #"> That should help. Robert B. Harrison Director of Interactive Services Austin & Williams 125 Kennedy Drive, Suite 100 Hauppauge NY 11788 P : 631.231.6600 Ext. 119 F : 631.434.7022 http://www.austin-williams.com Great advertising can't be either/or. It must be &. Plug in to our blog: A&W Unplugged http://www.austin-williams.com/unplugged -----Original Message----- From: Rick Sanders [mailto:c...@webenergy.ca] Sent: Thursday, October 21, 2010 10:23 AM To: cf-talk Subject: Writing cfml content to an html file Hey all, I'm trying to take some cfml content and write it to an html file using cffile. The cfml content has queries etc.... I'm getting all kinds of errors. Is there any way I can just get the cffile tag to write exactly what I want to the file parsing the cfml content? Error example: Invalid CFML construct found on line 18 at column 303. ColdFusion was looking at the following text: # The CFML compiler was processing: * A cffile tag beginning on line 1, column 2. The error occurred in E:\Websites\nscomputers\emailquote.cfm: line 18 16 : </tr> 17 : <cfquery name="sys" datasource="nscomputers"> 18 : SELECT S1.SystemID,S1.SessionID,S1.CPU,S1.RAM,S1.RAMqty,S1.MB,S1.HD,S1.HDqty,S1.Tow er,S1.Optical,S1.Video,S1.OS,S1.Keyboard,S1.Mouse,S1.Monitor,S1.Printer,S1.S peaker,S1.acc1,S1.acc2,S1.acc3,S1.acc4,S1.acc5,S1.acc6,S1.acc7,S1.acc8,S1.Su bTotal,S1.CreatedBy FROM dbo.SystemBuilder S1 WHERE (S1.SessionID='#cookie.sid#') 19 : </cfquery> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338431 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm