Before you apply this tip…
Create a function that hasn’t been defined yet and use the smart tag to generate a method stub.
You’ll get a method stub defined for bar() that throws a new Exception class.
But let’s say instead of throwing an Exception class, you wanted it to throw NotImplementedException.
Open up \Program Files\Microsoft Visual Studio 8\VC#\Snippets\1033\Refactoring\MethodStub.snippet
And change <Function>SimpleTypeName(global::System.Exception)</Function> to <Function>SimpleTypeName(global::System.NotImplementedException)</Function>
You could use this approach to define your custom method stubs as you see fit.
Tags: VSTips Suggest a Tip!