|
-
August 2nd, 2006, 01:36 AM
#1
How to copy file from one place to another....
Hi !!
In my application, I am downloading one file to my application path.Some times it is not downloading total file.In that my application is crashing.
For that I want to download that file to another place.If it is dowloaded correctly,then it is to copy to my application path.
For downloading,I wrote the code as follows....
int createFileMask = CFile::modeCreate | CFile::modeWrite | CFile::typeBinary;
CFile destFile(strDestFile,createFileMask );
while(byteswrite = pTargFile->Read(filebuf,512)){
destFile.Write(filebuf, byteswrite);
}
// Download ended, close file
destFile.Close();
Can any one please give me the solution for this problem..
And can I use the CopyFileEx method to solve this??If, How can I use this function..
Thanks & Regards,
klvin.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|