Appendix: Using Code SnippetsWith code snippets, you have all the code you need at your fingertips. The lab document will tell you exactly when you can use them, as shown in the following figure.
Figure 43
Using Visual Studio code snippets to insert code into your project To add a code snippet using the keyboard (C# only)
Figure 44
Start typing the snippet name
Figure 45
Press Tab to select the highlighted snippet
Figure 46
Press Tab again and the snippet will expand To add a code snippet using the mouse (C#, Visual Basic and XML)
Figure 47
Right-click where you want to insert the code snippet and select Insert Snippet
Figure 48
Pick the relevant snippet from the list, by clicking on it |