Jim, I use this wonderful tag and had a similar problem. I have a large
group of people who access the site for downloading information regarding
applicants for their departments.


I handle it by first CFSETing the file name appending the departmentID
(stored in the db) to the end of the file name..
<cfset outfile = "AppList#client.DeptID#.xls>

Next I check for that files existence on the server with CFFILE and if it
exists I delete it.

Then I run the CFX_Excel and plug in the
<cfif FileExists("d:/outdir/#outfile#")>
  <CFFILE Action="Delete" ...>
</cfif>

<CFX_Excel Query="roster"
Version="2000"
File="d:\templates\#outfile#"
Workbook="D:\TEMPLATES\GradeSheet.XLS"
Worksheet="Sheet1"
Headers="N"
Row="3"
Column="1">

That's it. My experience with cfcontent in our very mixed environment has
been less than stellar. I gave up, I just could not get all of the various
browser mime types to work (probably my lack of knowledge in that area). I
just create a page with a link to the file that they can click on to run the
file from the output location. I also provide a bunch of instructions for
Mac, PC and UNIX as well as instructions on how to use some of the Excel
tools (autofilter and pivot tables). This arrangement works very well for
us.

-Gary

> -----Original Message-----
> From: Jim Watkins [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 01, 2001 11:03 AM
> To: CF-Community
> Subject: CFX Excel Problem
>
>
> When more than one person attempts to activate the following tag
> at the same
> time the OUTPUT1.XLS file is not deleted and the next person gets
> an error.
> I then have to turn off the Webserver in NT Services and restart
> in order to
> delete the file so the script will run again.  Does anyone have a solution
> to this?
>
>
> <CFX_Excel Query="roster"
> Version="2000"
> File="d:\templates\OUTPUT1.XLS"
> Workbook="D:\TEMPLATES\GradeSheet.XLS"
> Worksheet="Sheet1"
> Headers="N"
> Row="3"
> Column="1">
> <cfheader name="Content-Disposition" value="inline;
> filename='Gradesheet.xls'">
> <cfcontent type="application/msexcel" file="d:\templates\OUTPUT1.XLS"
> deletefile="YES">
>
>
> Jim Watkins
> http://www.ngtcollege.org
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to