How to copy files from folder A to folder B

June 25, 2010 at 02:08:34
Specs: Windows Vista
Using C++ I need to write out a program to copy files from Folder A to Folder B. And I totally sucks at programming. So I hope is there anyone able to help me to write the full program out. Please.

See More: How to copy files from folder A to folder B

Report •

#1
June 25, 2010 at 03:59:33
At least have a stab at it then if you get stuck on something there are plenty of people willing to help but to do the whole thing for you is a professionals job and that costs money, especially if this happens to be a homework question.

It also helps if you put the question in the right forum. This is a programming question, nothing to do with networking.

http://www.google.co.uk/search?hl=e...

Stuart


Report •

#2
June 25, 2010 at 17:28:38
File systems are not defined in the C++ standard. Which OS are you programming for?

Report •

#3
June 27, 2010 at 20:11:06
Programming for windows

Report •

Related Solutions

#4
June 27, 2010 at 20:48:16
I'm willing to pay. Anyway I need to copy the files from one machine to another.

Report •

#5
June 27, 2010 at 21:12:46
I'm willing to pay. Anyway I need to copy the files from one machine to another.

LOL; you can't be serious.

#include <iostream>
#include <cstdlib>
#include <string>

using namespace std; 

int main(void){

   string inp = "";
   int pos;

   cout << "copy source, to destination (eg: c:\\, c:\\test): ";
   getline(cin, inp, '\n');      

   if((pos = inp.find(",")) != string::npos) {

      string cmd = "copy " + 
                   inp.substr(0, pos) + "*.* " +
                   inp.substr(pos + 1);   

      system(cmd.c_str());       
   }   

   return 0;
}

There you go; the most crude and buggy method imaginable... freebies come with no warranty or support though... user beware. :P


Report •

Ask Question