I have a script to collect logs. I want to collect more files residing at a different file location.I am using $logpath as a variable. Can anyone guide please.
$Logshare = "\\share\CMLogShare\"
#Get path for SCCM client Log files
$Logpath = Get-ItemProperty -path "C:\Windows\CCM\Logs"
$Log = $logpath
New-Item -Path $env:temp\SCCMLogs -ItemType Directory -Force
Copy-item -path $log\* -destination $env:temp\Sccmlogs -Force