Copying files from one directory to another directory.

futhon

Member
Joined
Feb 9, 2010
Messages
9
Programming Experience
Beginner
Hi, i am trying to move a file (test.txt) from say from:
C:\folder_A\test.txt
TO
C:\folder_B\test.txt
How am i suppose to do so?

I understand from the MSDN forum, i can use this
File.Copy(pathA, pathB) OR Directory.Move(pathA, pathB) where pathA = C:\folder_A\test.txt and pathB = C:\folder_B\test.txt

But it doesnt seem to work.. :(
 
i'm just taking guesses here:

Did you import System and System.IO ???
Also try
VB.NET:
File.Copy(pathA, pathB, True)
 
Back
Top