How to create a AddIn for Visual Studio 2008

I had to create a Visual Studio AddIn, no as simple task as I thought in the beginning.

What do you need.

Visual Studio 2008 SDK The Visual Studio 2008 Software Development Kit (SDK) 1.0 includes tools, documentation, and samples for developers to design, build, test and deploy extensions for Visual Studio 2008. You can also use the VS 2008 SDK 1.0 to create custom tools environments based on the Visual Studio 2008 Shell.

How to find the commands in VS2008 to attached to.

This example is looking for Tables …

for (int p = 1; p < ((Microsoft.VisualStudio.CommandBars.CommandBars)_applicationObject.CommandBars).Count; p++)
    Microsoft.VisualStudio.CommandBars.CommandBar menuBarCommandBarTemp = ((Microsoft.VisualStudio.CommandBars.CommandBars)_applicationObject.CommandBars)[p];

    for (int i = 1; i < menuBarCommandBarTemp.Controls.Count; i++)
        CommandBarControl con = menuBarCommandBarTemp.Controls[i];
        if (con.Caption.IndexOf("Table") > -1)

Have fun,



Published Tuesday, January 27, 2009 11:11 PM by albertpascual
Filed under: , , ,


# re: How to create a AddIn for Visual Studio 2008

Wednesday, January 28, 2009 12:22 PM by AndrewSeven

Try starting from the add-in project type, it includes resources for resolving the menu names for different languages