How To Register and Unregister an Out-of-Process COM Component (ActiveX EXE)

Article translations Article translations
Article ID: 297279 - View products that this article applies to.
This article was previously published under Q297279
Expand all | Collapse all

SUMMARY

This article describes how to register and unregister an out-of-process Component Object Model (COM) component. In Visual Basic, an out-of-process COM component corresponds to an ActiveX EXE file.

MORE INFORMATION

You can type these commands in a command window, or you can click Run from the Windows Start menu and type the commands.

To register the component, type the following command:
<path>\<mycomponent> /regserver
where <path> is the path to the component, and <mycomponent> is the name of your component.

To unregister the component, type the following command:
<path>\<mycomponent> /unregserver
where <path> is the path to the component, and <mycomponent> is the name of your component.

Visual Basic ActiveX EXE files register themselves the first time you run the EXE. However, you cannot use the EXE as a COM server until it is registered.

If you use the Package and Deployment Wizard or the Application Setup Wizard to distribute your ActiveX EXE, the EXE is registered automatically during application installation.

If you are working in the Visual Basic Integrated Development Environment (IDE), when you use the References dialog box to browse to the file location of an ActiveX EXE that is not registered, the component is registered when you add the EXE as a reference to the project.

Properties

Article ID: 297279 - Last Review: July 1, 2004 - Revision: 2.1
APPLIES TO
  • Microsoft Visual Basic 5.0 Enterprise Edition
  • Microsoft Visual Basic 6.0 Enterprise Edition
  • Microsoft Visual Basic 5.0 Professional Edition
  • Microsoft Visual Basic 6.0 Professional Edition
Keywords: 
kbhowto kblocalsvr KB297279

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com