I'm using the compiler CodeBlocks.
This is my program:
Here is what I don't know, How do I code the line that includes "system()" to let the program know that I want it to copy the file with the information the string has, to a directory another string has? Is it like this? Because when I do this, the program says: "The system cannot find the file specified."Code:string input; string output; input = "C:\\bla.txt\\"; //"Bla.txt" is the file to copy output = "C:\\test\\"; //"Test" is the folder to copy to system("copy input.c_str() output.c_str()")
So what do I do? I tried hard coding that line and it worked, so I know it has something to do with me writing "input.c_str()". What shall I change for this to work?
Thanks!