CopyFile

Pierrou

New member
Joined
Jul 6, 2017
Messages
186
Hello
I feel a bit stupid but can't get CopyFile to work
If I have a file named "image.png" in my C:/ folder why doesn't
code_language.cerberus:
CopyFile ("C:/image.png","C:/image2.png")
create a new file named image2.png?
What am I doing wrong?
Thanks!
 

Pierrou

New member
Joined
Jul 6, 2017
Messages
186
Seems I can copy the file to some folders like cerberus:// for example but not C:/, whereas I can create a dir using CreateDir in C:/
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,812
CopyFile works just fine. The problem might be that your OS doesn't allow copying the file in the C:/ folder without having admin rights.
Start the app with "Run as admin" and see if it works. I use Copyfile all over the place, but not in the root folder.
 
Top Bottom