Using the CFX_ExcelQuery tag at OpenXCF allows you to read and write real
XLS files.

-Matt

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> On Behalf Of cf coder
> Sent: Friday, August 20, 2004 12:32 PM
> To: CF-Talk
> Subject: exporting to csv or excel spreadsheet
>
> Hello everybody,
>
> I've written this code that exports the search results to a csv file. Here
> is the code:
>
> <CFFILE ACTION=""> >    FILE="searchResults.csv"
>     ADDNEWLINE="Yes"
>     OUTPUT="Date, Ref, Name #Chr(10)##Chr(10)#">
>
> <CFSET QUOTE = Chr(127)>
> <cfoutput query="qSearch">
> <CFSET log_string = QUOTE & LogTime & QUOTE & ","
> & QUOTE & Reference & QUOTE & ","
> & QUOTE & FirstName & QUOTE>
>
> <CFFILE ACTION=""> > FILE="searchResults.csv"
> ADDNEWLINE="Yes"
> OUTPUT="#log_string#">
> </cfoutput>
>
> <CFHEADER NAME="Content-Type" VALUE="application/unknown">
> <CFHEADER NAME="Content-Disposition" VALUE="inline;
> filename=searchResults.csv">
> <CFCONTENT TYPE="application/msexcel" FILE="searchResults.csv"
> deletefile="Yes">
>
>
> I was wondering if its possible that when the display the header
> information (Date, Ref, Name)
> with some background colour formatting to the text.
>
> So for example when the above code is executed, the .csv file opens up
> with 3 columns:
>
> Date     Ref Name
> 20/08/2004  T123345 Joe Bloggs
>
> Can I specify something in the code to for example make the header text
> colour to blue. If yes,
> can someone please show me the code or give me some tips.
>
> Best regards
> cfcoder
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to