What happens when you put a non-agile object in the CoreApplication Properties?
cppdashboard.dev/r/2026/11/what-happens-when-you-put-a-non-agile-object-in-the-coreapplThis article discusses the behavior of non-agile and agile objects in the CoreApplication Properties, explaining how they interact with apartment shutdowns and the use of RoGetAgileReference.
From the article
Last time, we noticed that non-agile objects in the CoreApplication. Properties appear to behave differently from agile objects .
I mean, it looks like they behave differently, but that’s only because you are taking too narrow a view.
They behave the same if you interpret the rule as “The objects remain alive until there are no more apartments that can access them.” Non-agile objects can be used only from the apartment that created them, whereas agile objects can be used from any apartment. Therefore, non-agile objects expire when their host apartment shuts down, whereas agile objects expire when all apartments shut down.
Share this resource