Different AppDomains platform in the same .NET process?

I am wondering: can I load a 32-bit x86-dll as a second AppDomain into an environment with 64-bit applications?

More details:

1) Main exe is a 64-bit C # pure.net 4 app;

2) The module is a third-party .net 2.0 shell of some unmanaged x86 dll;

So, can I create a second 32-bit AppDomain in the 64-bit version of .net 4 and load the 32-bit module into the newly created 32-bit AppDomain? And then the marshal between the default 64-bit AppDomain and the second 32-bit AppDomain?

Thanks for any advice!

+7
x86 64bit dll appdomain
source share
1 answer

This is not possible, bitness is a process property, not an appdomain property. To do this, you will need to load this DLL into a separate process. Use the standard .NET IPC mechanisms to talk to him. Named pipes, sockets, remote access, WCF. Or force the target setting of the platform to x86.

+7
source share

All Articles