It's as simple as this:elfo116 wrote:i'm trying to copy a file from one directory like: C:\Users\PC 1\Desktop\ , but its impossible cause he have a space (PC""1), anyone can help me to solve this ?
Code: Select all
source$="C:\Program Files\Internet Explorer\iexplore.exe"
target$="C:\Temp\"
CopyFile(source$,target$+GetFilePart(source$))
Also, you're using GetCurrentDirectory() in your snippet. Hope you're not using that to get the location of your app? Because that's not what it's for, and may be why your copy is failing. You need to use something like this at the start of your code:
Code: Select all
Global appdir$=GetPathPart(ProgramFilename())