On Wednesday, 13 July 2016 at 07:31:57 UTC, Adam Sansier wrote:
void** ptr = null;              
auto res = CoCreateInstance(&CLS_ID, cast(IUnknown)null, CLSCTX_INPROC_SERVER, &CLS_ID, cast(void**)&ptr);

How are you casting your "ptr" variable (which BTW should be just void* or usually IUnknown) to your interface? A common mistake if you're used to C++ is using cast(ISomeInterface*)ptr - which would cause access violations - instead of cast(ISomeInterface)ptr.

Reply via email to