News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

When to release an interface

Started by sinsi, March 06, 2019, 04:25:37 PM

Previous topic - Next topic

sinsi

Let's say I have an IShellFolder interface and get an IExtractIcon interface from it.
I want to use the IExtractIcon for a while but am finished with IShellFolder.

Can I release IShellFolder without affecting IExtractIcon? Or do I need to release IExtractIcon before IShellFolder?


aw27

I think you can, you are not inheriting from it.

Of course, you can also use the ExtractIcon API function.


sinsi

>I think you can, you are not inheriting from it.
That's what I thought (hoped) but C++ is beyond me.
The interface itself is simple (just a struct) but parameters like **ppv are a struggle.

>Of course, you can also use the ExtractIcon API function.
This is just a small part of a bigger project (desktop icons).

nidud

#3
deleted