Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 37007
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T14:28:58+00:00 2026-05-10T14:28:58+00:00

Part of my everyday work is maintaining and extending legacy VB6 applications. A common

  • 0

Part of my everyday work is maintaining and extending legacy VB6 applications. A common engine is written in C/C++ and VB6 uses these functions in order to improve performance.

When it comes to asynchronous programming, a C interface is not enough and we rely on COM controls to fire events to VB6.

My problem is that when I register the control in VB6, VB loads this control in memory and does not unload it until I quit the VB6 IDE. As the control is loaded the whole time, I am unable to recompile it in VC6, because the DLL file is locked.

A solution I found is not to enable the control in VB but use the CreateObject() with the full name of my control. The problem then is that I must declare my control as an Object because VB6 knows nothing of the interface I am using and I do not have access to IntelliSense, which is a pain.

Any idea how I can tell VB6 to unload controls after quitting the application or directly in the IDE ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T14:28:58+00:00Added an answer on May 10, 2026 at 2:28 pm

    I’m pretty sure there’s no good way to force VB6 to unload the control.

    Here’s what I do… instead of running Visual C and Visual Basic side-by-side, run VB6 under VC :

    1. Load up VC
    2. Open the project containing your COM objects
    3. Edit, change, etc.
    4. In VC, set the Output Executable to be VB6.EXE with appropriate command-line arguments to load the VB6 workspace
    5. Now just hit F5 to launch the VB6 IDE and load your VB6 project
    6. When you want to change the COM code again, exit VB6.EXE, make your changes, and hit F5 again. As long as you save your workspace VB6 will remember what windows you had open and all your project settings.

    Advantages of this method:

    • You can set breakpoints in the COM object and debug it using a full source debugger
    • You can happily debug in C and VB at the same time
    • Whenever VB6 is running it always has the latest version of the COM DLLs
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Part of my work is QA for data in some remote SQL servers. And
Part of a site I am building uses a javascript ajax request to hit
Part of a new product I have been assigned to work on involves server-side
Part of our java application needs to run javascript that is written by non-developers.
I'm developing a sharepoint 2010 application. One Part of these application is a List
We have a feed process which runs every day of the year. As part
Part of the GUI I'm building using tkinter has a pop-up window that says
Part of my web application is a background script that polls from a beanstalkd
Part of our website is protected with .htaccess style password protection. When you try
Part of my app caches web pages for offline viewing. To do that, I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.