Errol Farro
asked on
Cfspreadsheet to write to DOWNLOADS folder on loca PC
What is CFPREADSHEET syntax to have CF generate an Excel spreadsheet on the local PC in folder DOWNLOADS ?
ASKER
The CF runs on a server and is being access from a local PC.
When creating an Excel using <cfcontent type="application/msexcel" > <cfheader name="Content-Disposition" value="filename=Results.xl s">, the Results.xls file is always created on the local PC in the Downloads directory.
How can I get the same behavior using CFPSREADsheet but without specifying filename="C:\Users\userNam e\Download s" where userName is the user who has activated the CF application?
When creating an Excel using <cfcontent type="application/msexcel"
How can I get the same behavior using CFPSREADsheet but without specifying filename="C:\Users\userNam
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
<!--- get some sample data --->
<cfquery name="getCourses" datasource="cfdocexamples"
SELECT CORNUMBER,DEPT_ID,COURSE_I
FROM COURSELIST
</cfquery>
<!--- Write the query to a file --->
<cfspreadsheet action="write"
filename="c:\path\to\downl
query="getCourses"
sheetname="courses"
overwrite="true">