[DUG] Rename file issue using renamefile command

John Bird johnkbird at paradise.net.nz
Fri Jul 16 10:00:15 NZST 2010


Also Windows will prevent deleting or renaming a file it thinks is in use.   Check the open files section under Control Panel/administrative tools.  Sometimes even if a file is not listed there windows will still complain about it being in use.   Examples will be any file opened for reading by another program, or I have seen it sometimes even when the file has been recently closed.   Open Office documents cannot be attached into in email if they are still open in the program etc.   I have always suspected some caching issue might be behind these oddities.

If you can't rename, then plan B might be to copy the file and then overwrite the original.

On some sites I have seen a sort of similar issue - a Copyfile  command might either silently fail, or might end up with the destination file having the current date and time on it rather than the original...Only seems to be an issue on certain networks, and then only sometimes.

John Bird
JBCL
Contact:
johnkbird at paradise.net.nz
jbclnz at xtra.co.nz
027 4844528
http://jbclnz.googlepages.com



From: Vik Vasudev 
Sent: Friday, July 16, 2010 4:20 AM
To: NZ Borland Developers Group - Delphi List ; NZ Borland Developers Group - Delphi List 
Subject: [DUG] Rename file issue using renamefile command


Hi Everyone,

I am facing a problem using the rename function in delphi 6. 

We are using a Banking application where our client normal do End of day processing during end of day. During that time we process lot of file and rename it

say for example from xyx.txt to xyx.001 and xyz.002 etc.

But one of my client says he is getting error while the file getting renamed. I just checked all the read access rights credential and everything seems alright. And there is no locking too.It dont happen for him in every location except in one branch.

I just wonder if anyone ever come across this problem since i am not able to figure out what could be the reason other than file rights

Regards
Vik





--------------------------------------------------------------------------------


_______________________________________________
NZ Borland Developers Group - Delphi mailing list
Post: delphi at delphi.org.nz
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to delphi-request at delphi.org.nz with Subject: unsubscribe
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listserver.123.net.nz/pipermail/delphi/attachments/20100716/5ed906c0/attachment.html 


More information about the Delphi mailing list