Re: Callbacks from unmanaged code to managed code

Tibor Bekesi <[email protected]> Tue, 25 Jun 2002 11:58:34 +0200
Newsgroups gmane.comp.windows.devel.dotnet.general
Message-ID <[email protected]>
Dear Axel,

Maybe You can find some hints that You can use at
http://localhost/quickstart/howto/ at the Interoperability section.
(http://localhost/quickstart/howto/doc/Interop/Building_Samples_COM2NET.
aspx )

Best regards,
Tibor

-----Original Message-----
From: The DOTNET list will be retired 7/1/02
[mailto:[email protected]] On Behalf Of Axel Heitland
Sent: Tuesday, June 25, 2002 12:07 AM
To: [email protected]
Subject: [DOTNET] Callbacks from unmanaged code to managed code

Dear list,

It's quite easy to call unmanaged functions from MC++ and it's easy to
hold a reference to a managed type from unmanaged code as well.

But how the heck can I call a managed function (i.e. an instance member
function) from unmanaged code?!

A direct call is treated as an error by the compiler - is it really so
hard to support this? And if that doesn't work, what's the workaround?

I know that this has been asked before, but the answers in the archives
aren't satisfying :-(

Any pointers are highly appreciated
        Axel

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.