Get last exception type in Powershell
Solution
This is the name you should use to catch a specific exception.
$Error.Exception.GetType().FullName
Source
Was this post helpful?
Let us know if you liked the post. That’s the only way we can improve.