7Zip4Powershell
7Zip4Powershell copied to clipboard
ErrorAction Parameter for Get-7Zip and Get-7ZipInformation
Hello:
When attempting to open an encrypted archive with the wrong password, an exception is correctly thrown, but the -ErrorAction parameter appears to not be respected. For example:
Get-7Zip -ArchiveFileName .\Encrypted.7z -Password "WrongPassword" -ErrorAction SilentlyContinue
Is not silent. And "-ErrorAction Stop" does not stop.
Both Get-7Zip and Get-7ZipInformation appear to not respect -ErrorAction, but Expand-7Zip does (haven't tried the other cmdlets).
Thanks for the module! Cheers, J.
Up to now I didn't implement any error handling at all. I'll have a closer look.