devxlogo

Expose Multiuse Classes in ActiveX Control Projects

Expose Multiuse Classes in ActiveX Control Projects

A lesser-known, new feature in VB6 is the ability to have MultiUse and GlobalMultiUse classes within an ActiveX control project. This is useful if you have ActiveX controls and creatable classes you want to expose from the same project. There was no way to do this in VB5. In VB6, it’s as easy as adding a class module to your ActiveX control project. Unfortunately, there’s no way to do the converse; you can’t have a public user control in an ActiveX DLL project. So, if you want creatable classes and public user controls in the same project, you have to make it an ActiveX Control project. If you prefer your component to be a DLL instead of an OCX, just rename the file; internally, an OCX is the same as a DLL.

See also  How to Avoid Money Transfer Scams  
devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist