Is This Content Helpful?
We're glad to know this article was helpful.
Do I have to explicitly instantiate a singleton?
Sometimes, when using the new keyword to instantiate a COM object, a reference to an object that already exists is returned. This happens when attempting to instantiate a singleton class that has previously been instantiated. The solution is to use the Activator class to safely wrap singleton objects in a strongly typed runtime callable wrapper (RCW), when a reference to them is first obtained.