Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[Help] Visual Basic 2010 Copying Files

Custom Title Activated
Member
Joined
Mar 17, 2009
Messages
1,911
Reaction score
538
I'm making a program in Visual Basic 2010, A user clicks a button to move a file to a specific folder.

Yes, I do checks to see if they have the right file path.

But, when it comes to copying the file It gives me an acess denied message, I've ran it as Administrator and changed the folder permissions. Any help?

Thanks,
Daniel
 
Joined
Apr 1, 2010
Messages
1,364
Reaction score
293
System.IO.File.Copy(sourceFileName, destinationFileName)

or

My.Computer.FileSystem.CopyFile(sourceFileName,destinationFileName)

Both is the same.

For copying folders use

My.Computer.FileSystem.CopyDirectory(sourceFolder,destinationFolder)
 
Last edited:
Custom Title Activated
Member
Joined
Mar 17, 2009
Messages
1,911
Reaction score
538
I know, I use the above codes but It gives me access denied =="
 
Back
Top