0

Hi Im new to the whole thing of programming and would like to write a C++ program to copy files from one drive to another, any help and suggestions on where to start?

Any help with source code or pointers will be greatly appreciated. The OS the program is for is WINCE 4.2 .net embedded.

Thanks in advance

3
Contributors
2
Replies
3
Views
9 Years
Discussion Span
Last Post by dougy83
0

To copy a file you basically need to first read that file. To do this read about opening ifstreams as binary files ( http://www.cplusplus.com/reference/iostream/istream/read.html ), might want to edit that code a bit. Then you'll want to save the contents of what you read to an output file, ofstream is your weapon of choice here ( http://www.cplusplus.com/reference/iostream/ostream/write.html )... In fact the latter link has basically your program... Write some user-input/command line parameter processing around it to allow a user to select the input and output files and hey presto done.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.