Datasheet
Useful Features of Visual Studio 2010
❘
59
7. In the small toolbar, press the Stop button.
8. Select Tools ➪ Macros ➪ Macro Explorer. The Macro Explorer will appear (in the location normally
occupied by the Solution Explorer), with the new macro in it (see Figure 1 - 40). You can name the macro
anything you like. Note that the Macro Explorer ships with several sample macros that you can “ explore. ”
FIGURE 1 - 40
FIGURE 1 - 41
9. Right - click the macro and select Edit to get to the Macro Editor. You will see the following code, as
shown in Figure 1 - 41, in your macro:
DTE.ActiveDocument.Selection.NewLine()
DTE.ActiveDocument.Selection.Text = TextBox1.Text = “Macro Test”
DTE.ActiveDocument.Selection.NewLine()
CH001.indd 59CH001.indd 59 4/5/10 11:57:04 AM4/5/10 11:57:04 AM