CopyFileEx and partially locked files

Discuss and announce Total Commander plugins, addons and other useful tools here, both their usage and their development.

Moderators: Hacker, petermad, Stefan2, white

Post Reply
Lobuno
Junior Member
Junior Member
Posts: 2
Joined: 2010-02-24, 16:11 UTC

CopyFileEx and partially locked files

Post by *Lobuno »

Hello!

I am trying to use the function CopyFileEx with partially locked files (like pst or ost) when developing a plugin (Delphi 2010) but it sometimes hangs the plugin (and the whole TC).

I read in the "What's new" that Ghisler solved that problem somehow. Could I get a hint how? Sometimes the copy begins OK but it just hangs in the middle forever. Closing outlook doesn't solve the problem once the program is frozen.
User avatar
nsp
Power Member
Power Member
Posts: 1917
Joined: 2005-12-04, 08:39 UTC
Location: Lyon (FRANCE)
Contact:

Re: CopyFileEx and partially locked files

Post by *nsp »

Lobuno wrote:Hello!

I am trying to use the function CopyFileEx with partially locked files (like pst or ost) when developing a plugin (Delphi 2010) but it sometimes hangs the plugin (and the whole TC).

I read in the "What's new" that Ghisler solved that problem somehow. Could I get a hint how? Sometimes the copy begins OK but it just hangs in the middle forever. Closing outlook doesn't solve the problem once the program is frozen.
I do not know for TC but most of the backup software use :
A) Internal File Driver
B) VSS ( Microsoft Volume Shadow Services)

for (B), you can check for Shadow Copy, Hobocopy (SourceForge with source), ...

Edited....
it seems that robocopy /B (backup mode) is able to copy it.
Lobuno
Junior Member
Junior Member
Posts: 2
Joined: 2010-02-24, 16:11 UTC

Re: CopyFileEx and partially locked files

Post by *Lobuno »

Yes, I know about VSC but my problem is not that the file is not being copied. I'm OK with that. I only want that, if it's not possible to copy, the function would fail, like it does with any normally locked file. But with partially locked files CopyFileEx is not returning at all!!!!
Post Reply