Home > database >  Can you create a 32-bit AppDomain from a 64-bit process?
Can you create a 32-bit AppDomain from a 64-bit process?

Time:07-20

Is it possible to create an AppDomain to host/run some 32-bit code from a 64-bit process, and then be able to pass/marshal data from the newly created AppDomain to host AppDomain?

I could do this as an out-of-process executable, but I am trying to avoid having a large binary foot-print for the 32-bit process (which happens to be a stand-alone .NET 6.0 console executable).

CodePudding user response:

You can't half on the same process to run as 64 bit and the other as 32 bit. So even if .Net 6 would support creating AppDomains (which it does not) creating 32bit AppDomain in 64bit process would not work.

You need to create separate processes for that which may share most of the code /binaries - you only need bootstraping app to be explicitly 32 or 64 bits, the rest of your assemblies can be "Any".

  • Related