Pascal Scripting: CopyFile

Prototype

function CopyFile(const ExistingFile, NewFile: String; const FailIfExists: Boolean): Boolean;

Description

Copies ExistingFile to NewFile, preserving time stamp and file attributes.
If FailIfExists is True it will fail if NewFile already exists, otherwise it will overwrite it.
Returns True if successful, False otherwise.

Files copied using CopyFile are not automatically uninstalled. Consider using a [Files] entry with the external flag set instead.

Remarks

Can't be used to copy Setup itself until the installation has started.