about_IOInfoExtensions.PowerShell_CopyFrom.help.txt
TOPIC
about_IOInfoExtensions.PowerShell_CopyFrom SHORT DESCRIPTION Copies the source file to the calling destination file. If the destination file exists and overwrite is false, then no changes are made. System.IO.FileInfo has a CopyTo method, but it returns the destination object. This performs the copy and updates the passed objects to avoid having to reassign/recreate them. SYNTAX CopyFrom(System.IO.FileInfo source, [bool overwrite = False]) PARAMETERS source <System.IO.FileInfo> The source FileInfo object to be copied. Required: True Default Value: Accepts Wildcard Characters: False overwrite <System.Boolean> Indicates if the destination file should be overwritten if it exists. Required: False Default Value: False Accepts Wildcard Characters: False EXCEPTIONS System.IO.FileNotFoundException If the source file does not exist. KEYWORDS IOInfoExtensions, IOInfoExtensions.PowerShell, System.IO.FileInfo, FileInfo, CopyFrom SEE ALSO about_IOInfoExtensions.PowerShell about_IOInfoExtensions.PowerShell_GetDirectory about_IOInfoExtensions.PowerShell_GetFile about_IOInfoExtensions.PowerShell_DeleteContent about_IOInfoExtensions.PowerShell_CopyContentTo about_IOInfoExtensions.PowerShell_MoveFrom about_IOInfoExtensions.PowerShell_CopyFrom about_IOInfoExtensions.PowerShell_TryDelete |