IF fFileExist("FILE1.TXT") THEN
IF fDriveInfo(fCurrentDrive(),fdFreeSpace) > fSize("FILE1.TXT") THEN
IF fCopyFile("FILE1.TXT","COPY1.TXT") THEN
Info("FILE1.TXT successfully copied to COPY1.TXT")
FILDEL..State = Active
ELSE
Error("Problem while copying FILE1.TXT to COPY1.TXT")
END
ELSE
Error(StringBuild("Unable to copy: insufficient space on %1", fCurrentDrive()))
END
ELSE
Error("FILE1.TXT is not in the directory",...
fCurrentDir())
END
---
IF fDirectoryExist(gsDir1) THEN
fCopyDir(gsDir1,fCurrentDir()+"\CopyDir",frProgress+frConfirm+frRecursive)
IF ErrorOccurred THEN
// An error occurred while copying the directory
Error(StringBuild("Error while copying the directory: %1",gsDir1),ErrorInfo())
RETURN
END
ELSE
Error(StringBuild("Directory: %1 not found in directory: %2",gsDir1,fCurrentDir()))
END
Nenhum comentário:
Postar um comentário