Link to home
Start Free TrialLog in
Avatar of Andy1
Andy1

asked on

Copy a file using Volume Shadow Service

I am using Visual Studio 2008 working with VB.NET.

What I want to do is create a small app for myself that can make a copy of some of my files which are often locked by the system.

I'm told this can be done in a way, you can get a copy of whats written on the disk by accessing a snapshot of the file using the volume shadow service. I understand this may not be the entire file if data hasn't yet been written.

Can anyone provide me with a function which can access the VSS API for XP or Vista where I can pass it the path/name of the source file and the path/name of the destination file and have it make the copy?

Cheers.
Avatar of ChetOS82
ChetOS82
Flag of United States of America image

Have you looked at the Volume Shadow Service SDK?  http://www.microsoft.com/downloads/details.aspx?FamilyID=0b4f56e4-0ccc-4626-826a-ed2c4c95c871&DisplayLang=en

Also, there is a CodeProject page giving a use like yours: http://www.codeproject.com/KB/dotnet/makeshadowcopy.aspx
Avatar of Andy1
Andy1

ASKER

I still haven't gotten far with this... i had already downloaded the sdk.
ASKER CERTIFIED SOLUTION
Avatar of Andy1
Andy1

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial