Setting Up a Static Link to the Registrar Code (C++ only)

C++ clients can create a static link to the Registrar's code. Static linking of the Registrar's parser adds approximately 5K to a release build.

The simplest way to set up static linking assumes you have specified DECLARE_REGISTRY_RESOURCEID in your object's declaration. (This is the default specification used by the ATL.)

To create a static link using DECLARE_REGISTRY_RESOURCEID

  1. Open the Project Settings dialog box, select the C++ tab. In the Preprocessor Definitions text box, replace _ATL_DLL with _ATL_STATIC_REGISTRY.

  2. Recompile.

If the project has been created using the ATL AppWizard, you only need to select the Win32 Release MinDependency option, which has the correct preprocessor definitions for statically linking to the registrar code.