PowerShell - Error Handling
You run this script but it continues unexpectedly:
What is the likely cause?
Try {
Get-Item 'C:\nonexistentfile.txt' -ErrorAction Stop
} Catch {
Write-Output 'Caught error'
}
Write-Output 'Script continues'What is the likely cause?
