The Process for Creating Add-ins

Home Page (Add-ins)OverviewHow Do I ... TopicsFAQReference

Following is a summary of the process for creating an add-in. For step-by-step instructions, see How Do I ... Topics: Add-ins to the Visual C++ Developer Studio.

Note   ATL objects in a Developer Studio Add-in project will cause a project build to fail.  Therefore, you should avoid using the New ATL Object option in the Insert menu in a Developer Studio Add-in project.

  1. Decide which language to use.

    You can use Visual C++ or Visual Basic versions 4.0 or later. If you use Visual C++, you can use the included Developer Studio Add-in Wizard, which does most of the work for you.

    If you use Visual Basic, you must use the Developer Studio type libraries to access the Developer Studio object model. The names and locations of these libraries on your computer are as follows:

    • Build system (Microsoft Visual Studio\Common\MSDEV98\Bin\Ide\Devbld.pkg)

    • Debugger (Microsoft Visual Studio\Common\MSDEV98\Bin\Ide\Devdbg.pkg)

    • Developer Studio shell (Microsoft Visual Studio\Common\MSDEV98\Bin\Devshl.dll)

    • Text editor (Microsoft Visual Studio\Common\MSDEV98\Bin\Devedit.pkg)

  2. Create a project for the add-in.

    If you create a Visual C++ add-in with the Developer Studio Add-in Wizard, a project is created for you. If you create a Visual Basic add-in, start with one of the sample Visual Basic add-ins. For details, see Creating Add-ins Using Visual Basic.

  3. Write additional code for the add-in.

    If you use the Developer Studio Add-in Wizard or the Visual Basic samples, most of the code is already written — including the code that adds a command to the Visual C++ environment.

  4. Build the DLL from the source files the Add-in Wizard creates.

    Remember that you can combine several add-ins into one DLL.

  5. Connect the add-in to the Visual C++ environment.

    When you connect the add-in, it adds its commands to the Visual C++ development environment. For details, see Connecting Add-ins to the Development Environment.

  6. Carry out the commands added to the environment.

    You can run these commands from the command line, or you can carry them out by clicking toolbar buttons or pressing keys associated with the commands. For details, see Carrying Out Add-in Commands.