I am setting up a dll that automatically creates a date/time stamped copy of my Database Backup before I overwrite it with a new backup. As the DB backup has got bigger, the copy process has started to take over my processor for the 10-minutes it takes to do the copy (backup is now in the 2Gb size).
Is there a way I can change the code below to run as a 'background' process, or a way to restrict the amount of PC resource it can grab?
I am currently using a very simple:
Code:
do
{
dwRead = sourceFile.Read(buffer, blocksize);
destFile.Write(buffer, dwRead);
}
while (dwRead > 0);