|
From: Zodiaq <zo...@ac...> - 2002-12-21 19:13:20
|
Hello j and all Dev-C++ users, Saturday, December 21, 2002, 7:08:19 PM, j wrote as follows: jb> i have a small question bout file processing... i can write to a jb> file and read from a file but i cannot copy a file's content to the jb> other... anyone who can help?? First: be more precise in future - for example which functions would you like to use to copy files - provided by C++ or system? Second: if you know how to read and write what is the problem?? Use localy some buffer for temporary data, then read from first, and write to second... important is to to do it in binary mode - if you are using fopen functions do it like this: FILE input = fopen( "file", "br" ); or if you want to use system functions use CopyFile(Ex): CopyFile( "source", "destination", FALSE ); //FALSE means overwrite if exists... more info in online msdn: http://msdn.microsoft.com/library/en-us/fileio/base/copyfile.asp jb> kind regards... -- regards, Zodiaq |