I have a powershell script to fetch all the files in a folder but exclude all the files in a sub folder. I am using the following script, but not giving the expected results.
Get-ChildItem -Path $srcpath -Force -Exclude "Monthly Reports" -Recurse
Note: Trying to exclude the files in the sub folder "Monthly Reports"