One of the things you have to do often is to declare a pointer, create a new object instance, and retrieve an interface via CoCreateInstance. There's a convenience method in CComPtr<T> to make this a 1-step process.
To handle remote activation in DCOM using CoCreateInstanceEx, we can extend CComPtr<T> by inheriting from it and adding the necessary method. It's crucial to be aware that local activation may actually occur on a remote server due to DCOM configuration.
Collection
[
|
...
]