Not that this is likely to help you, but there is a Windows resource kit
utility called "oh" (for Open Handles) that will show all open files and
the processes that have them open.  This is a debugging tool only (it's
slow), but you might be interested in knowing if ftp, iis, or cf
actually has the file open.  I have been surprised in the past when I
assumed that I knew who had a file open.

Also, can you try renaming the file from code? Maybe that will be enough
to let the upload work the second time.

I'm reading your post again, and if the XLS file is being used as a
datasource then you ought to expect that it is open... CF is querying
it!  Maybe you need to release all your existing "db" connections, like
on the datasources admin screen... I think there was a way to do that
from code.

Anyway, good luck.

        Mark

-----Original Message-----
From: T Burke [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 05, 2007 3:15 PM
To: CF-Talk
Subject: How to Check for Open Files....

I have a client who uploads an excel spreadsheet daily (FTP), which is
her datasource to her CFMX website.

Unfortunately, the file gets uploaded then locks up so that she cannot
upload the next day, nor can the file be deleted w/o contacting
technical support to delete (Windows servers). I suspect the client is
attempting to upload while she has the spreadsheet OPEN, which is turns
hozes up the files permissions and locks.

Is there a way to 1) Check to see if the file is open or in use or 2)
require the file to be closed before she uploads. Can this be done in
CF?

Suggestions, comments, ideas... All are most welcome. I am considering
either writing a script that performs the uploads for her or writing a
script that will suck her excel spreadsheet into a MySQL database (ugh).
If we can keep it simple though, and just get a good, consistent upload
of the xls file, that would be ideal.

Tx, DG



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Upgrade to Adobe ColdFusion MX7 
Experience Flex 2 & MX7 integration & create powerful cross-platform RIAs 
http:http://ad.doubleclick.net/clk;56760587;14748456;a?http://www.adobe.com/products/coldfusion/flex2/?sdid=LVNU

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:268750
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to