ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old November 29th, 2011, 10:42 AM
korssane korssane is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2011
Posts: 60 korssane User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 22 m 2 sec
Reputation Power: 2
CF MX 7 close file

Hi Peers,
i am wondering if there is a way to close a file in CF MX 7 .
i tried to google that but seems this function does not exist in CF MX 7 and i really want that close file as i have to wait for more than 3 min to delete my file

thanks

Reply With Quote
  #2  
Old November 29th, 2011, 03:48 PM
kiteless kiteless is offline
Moderator
Dev Shed God (5000 - 5499 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 5,091 kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 2 Weeks 5 Days 2 h 53 m 27 sec
Reputation Power: 966
Can you explain what you mean by "close a file"?

Reply With Quote
  #3  
Old November 29th, 2011, 04:35 PM
korssane korssane is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2011
Posts: 60 korssane User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 22 m 2 sec
Reputation Power: 2
Quote:
Originally Posted by kiteless
Can you explain what you mean by "close a file"?


hi there ,

I need to close a file that is actually used by other program.
iam initially loading that xls file..and after using it i have to delete it from my temp folder.. The issue is when users load some corrupted files , i have to wait 2 min to be able to delete that file.
since that file is still open , i want to be able to close it and then delete it without waiting 2 min.


thanks

Reply With Quote
  #4  
Old November 29th, 2011, 04:52 PM
kiteless kiteless is offline
Moderator
Dev Shed God (5000 - 5499 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 5,091 kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 2 Weeks 5 Days 2 h 53 m 27 sec
Reputation Power: 966
I'm still not following. If it's a file system issue lock, then CF can't do anything with the file until the lock at the file system level is released. What is locking the file and keeping it open? Is someone actually OPENING the file in some other program (like Excel)?

Reply With Quote
  #5  
Old November 29th, 2011, 05:14 PM
korssane korssane is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2011
Posts: 60 korssane User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 22 m 2 sec
Reputation Power: 2
Quote:
Originally Posted by kiteless
I'm still not following. If it's a file system issue lock, then CF can't do anything with the file until the lock at the file system level is released. What is locking the file and keeping it open? Is someone actually OPENING the file in some other program (like Excel)?


No, basically users try to load a corrupted xls 2003 file ..basicalkly they just save a 2007 as 2003 and try to load it as 2003. the converted file will not be proceeded and consequently enter in a loop for a 1-2 min...which means the file is open..

Iam trying to close the file 1st before deleting it...

My need is ,,is there a way to close a file in CF 7 as i could not find any information in livedocs about something like <cffile action="close" ...ie

not sure if it is clear..?

Reply With Quote
  #6  
Old November 29th, 2011, 09:08 PM
kiteless kiteless is offline
Moderator
Dev Shed God (5000 - 5499 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 5,091 kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 2 Weeks 5 Days 2 h 53 m 27 sec
Reputation Power: 966
No, sorry, its still not clear. A file is just binary data. Neither ColdFusion nor the operating system know or care if it is an Excel 2003 or 2007 file. That only matters to Microsoft Excel.

I think you're still not explaining some part of what is going on. When you say the user "saves it as 2003" and then "loads it as 2007", what does that mean? Does "save" mean UPLOADING this file to the server using CFFILE? Does "load" mean DOWNLOADING this file? Or does "save" mean actually saving the file from Excel to the hard drive on the server? And "load" mean opening the file in Excel from the hard drive on the server?

Reply With Quote
  #7  
Old November 29th, 2011, 09:11 PM
kiteless kiteless is offline
Moderator
Dev Shed God (5000 - 5499 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 5,091 kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level)kiteless User rank is General (90000 - 100000 Reputation Level) 
Time spent in forums: 2 Weeks 5 Days 2 h 53 m 27 sec
Reputation Power: 966
Also, to be clear, if the USER is opening the file and creating the lock, then no, CF can't delete the file. The whole point of a lock on a file is to stop anything else from doing something to the file.

You *might* be able to force delete it by running a command line delete, but I think that would require System Admin permissions which is a very dangerous thing to assign to web-based processes.

Last edited by kiteless : November 29th, 2011 at 09:14 PM.

Reply With Quote
  #8  
Old November 30th, 2011, 07:20 AM
korssane korssane is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2011
Posts: 60 korssane User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 22 m 2 sec
Reputation Power: 2
Quote:
Originally Posted by kiteless
Also, to be clear, if the USER is opening the file and creating the lock, then no, CF can't delete the file. The whole point of a lock on a file is to stop anything else from doing something to the file.

You *might* be able to force delete it by running a command line delete, but I think that would require System Admin permissions which is a very dangerous thing to assign to web-based processes.


ok i got it

Thanks kiteless.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > CF MX 7 close file

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap