Wednesday, February 13, 2008

Getting a list of .NET exceptions with Resharper.

Often I'm programming C#.NET and want to throw an exception but I don't know what exception to throw. I think "wouldn't it be nice if there was an easy way to get a list of the exceptions in .NET?"

I've Googled, I've dug thru the MDSN, then it hit me...

DUH! Resharper's intellisense.

A simple "throw new" gives you:



And you can use the "Navigate from here to Base" feature to get a more detailed list.

Just type "System.Exception" and hit the Resharper 2.x shortcut: Ctrl + Alt + B


No comments:

Post a Comment