Copy-Function
Aus Wiki-WebPerfect
Function Copy-DirectoryDontent { [CmdletBinding()] param( [Parameter(Position=0,mandatory=$false)] [array] $ComputerNames, [Parameter(Position=1,mandatory=$false)] [string] $SourceShare, [Parameter(Position=2,mandatory=$false)] [string] $Destination ) process { $SourceShare = "<Source-Share>\*" $Destination = "C$\<Destination-Path>" Foreach ($_ComputerNames in $ComputerNames) { Copy-Item -Path "\\$SourceShare\" -Destination "\\$ComputerName\$Destination" -Recurse -Force } } }