We need you!

We're working hard on the next version of Developer Fusion. Let us know what you think we should be up to!

Members

Technology Zones

Articles

Hosted By

MaximumASP

Info

Rated
Read 22,060 times

Contents

Related Categories

Keeping VB Components Compatible - Has Your Reference Gone Missing?

LACanadian

Has Your Reference Gone Missing?

As you might guess, the possible problems that can arise while playing with compatibility are relatively large. And, for the most part, a pain in the butt to debug. At some point in your coding career, odds are pretty good that you will run into the following error message:

"Connection to type library or object library for remote process has been lost"

Let me outline a number of reasons for this behavior in the hopes that you might find enlightenment. (Just call me the VB Buddha :)

If this is a new project, you have probably just compiled it for the first time. A new CLSID is generated, one that the calling project knows nothing about. So go into the calling project and add the class in question to the reference list.


If you're debugging your project by running two instances of Visual Basic, not keeping the class project running will trigger this message. Makes sense. If all of a sudden you were to delete one of the components defined to a project, you would expect the same Missing Reference error.
One final piece of experience that I'd like to leave you with. If you're trying the debug server side ASP components by having Visual Basic running along side the web server, then you need to be particularly aware of the compatibility setting. Otherwise the registry entries necessary to get that specific debugging mode are will not be set correctly. And you will find that the web server never seems to hit the break point you've put into your code. You'll be left scratching your heard and cursing the gods of computing. Again, take the word of a man with experience.

I am the owner of a small application development consulting company that specialized in the design and implementation of Internet-based applications. While there are others who can make a web site look good, our expertise is in making the site function. This includes infrastructure design, database design and administration, software development and deployment. For the most part, we utilize Microsoft-based languages and tools. And we are skilled enough to have generated two patent applications for our clients.

Comments

  • Removing old references

    Posted by LACanadian on 31 Jan 2003

    When I've had the same problem, I would follow these steps:

    1. Manually unregister the component with regsvr32 /u [i]path[/i].

    2. Edit the registry using your favorite tool

    3. Starting in ...

  • How to remove old references?

    Posted by dhnc on 21 Nov 2002

    Very interesting article on component compatibility. It gave me good insight in something I had trouble with during a long time already.
    I have the following question though:
    how can you remove the ...

  • Very Good

    Posted by pleitch on 10 Jul 2002

    Looks like it is straight out of a text book. I checked through it all and it is all correct. I had to by a series of advanced COM/COM++/VB and COM books to decypher - ah I mean learn - the same inf...