How to create component in AppDomain

  • Thread starter Thread starter Chris Walker
  • Start date Start date
C

Chris Walker

On the desktop, I can create an AppDomain and then load an assembly into
it -- and then create a component in that appdomain and get a reference to
it.

With the compact framework, I can create an AppDomain and launch an
executable in it.

How can I load an assembly into an AppDomain under Windows CE, and then how
can I create an instance of a component from that DLL?

Under .NET, I would do something like:
newAppDomain.CreateInstanceFromAndUnwrap(assemblyPath,
"Project1.AppDomainTestComponent")

Under .NET CF, I have no idea :)

Chris
 
CreateInstanceFromAndUnwrap is not supported on the CF. I believe you are
probably out of luck in this area.

Cheers
Daniel
 
So is there no way to create an AppDomain in which to create an object? As
it stands right now, it seems that .NET CF only allows AppDomains to launch
additional programs, basically.

There is a project on the Internet (without source available) called NADABS
which purports to do exactly this under .NET CF.

Chris
 
You pretty much have the picture... Usually when you manually load an
appdomain it is because you would like to manually unload it later... that
is not supported either (or unloading assemblies). Sounds like you have to
design around this.

Cheers
Daniel
 
Hi,

have u figured out a way to solve that problem ( i.e AppDomain.Unload) ?
How about NADABS ?? it seems to solve the problem, but will they be willing
to give the source code?
+ plz any idea if this is solved in CF 2.0 ?

kindly send reply to rawadkhalife<AT>gmail.com or on this forum.
tnx
 
Back
Top