Datasheet

Figure 1-59: If the code editor can figure out what’s wrong, it displays a suggestion indicator.
Code Snippets
A code snippet is a piece of code that you might find useful in many applications. It is stored in a snippet
library so that you can quickly insert it into a new application.
Visual Studio comes with hundreds of snippets for performing standard tasks. Before you start working on
a complicated piece of code, you should take a look at the snippets that are already available to you. In fact,
it would be worth your time to use the Snippet Manager available from the Tools menu to take a good look
at the available snippets right now before you start a new project. There’s little point in you reinventing
methods for calculating statistical values if someone has already done it and given you the code.
Snippets are stored in simple text files with XML tags, so it is easy to share snippets with other develop-
ers. Go to this book’s web page,
www.vb-helper.com/vbprogref.htm, to contribute snippets and to
download snippets contributed by others.
The following sections explain how to use snippets in your applications and how to create new snippets.
63
Chapter 1: IDE
37055c016.qxd 4/8/07 12:46 PM Page 63