Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Copying Files from one location to another

Status
Not open for further replies.

muthuivs

Technical User
Jan 30, 2006
36
CA
Anyone know what function will copy contents from one folder to another, I know the source folder and the destination aso I dont have to use the mkdir. Any Ideas?


Muthu
 
Code:
system("xcopy source target /E");
You may form the cmd string on the fly by strcat or strstream.
 
How does this syntax work, can you give me an example ? and what library should I add to have it work?
 
The system() is a function from the standard C++ run-time library (execute a command, prototype in <cstdlib> header, see RTL help); xcopy is a standard Windows extended copy command (see Win help or type xcopy /? in a console window. What's an example are you need? system("cmd parameters") is an example.
Any Ideas?
That's the idea (and a tool w/o mkdir;)...
 
Thanks. Appreciate your time and expertise.

Mu2
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top