Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources
Viewing all articles
Browse latest Browse all 8583

Getting Exception Types that PowerShell might handle

$
0
0

In the traditional try/catch block, you might have something that looks like this:

Try {
#  some dodgy code
}

Catch [<exception 1>] {"exception 2"}
Catch [<exception 1>] {"exception 2"}

Two questions:

1. Where is the set of exceptions that PowerShell can handle documented?

2. Is there some magic incantation to display all the exceptions types in existance?


Viewing all articles
Browse latest Browse all 8583

Latest Images

Trending Articles



Latest Images