Frequently asked question

Do I have to explicitly instantiate a singleton?

Last Published: October 1, 2025
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.

Article ID: 000009964

Software:
  • ArcGIS Engine

Get support with AI

Resolve your issue quickly with the Esri Support AI Chatbot.

Start chatting now

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Start chatting now

Go to download options