PC Review


Reply
Thread Tools Rate Thread

How to create component in AppDomain

 
 
Chris Walker
Guest
Posts: n/a
 
      1st Dec 2004
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



 
Reply With Quote
 
 
 
 
Daniel Moth
Guest
Posts: n/a
 
      1st Dec 2004
CreateInstanceFromAndUnwrap is not supported on the CF. I believe you are
probably out of luck in this area.

Cheers
Daniel
--
http://www.danielmoth.com/Blog/


"Chris Walker" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> 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
>
>
>



 
Reply With Quote
 
Chris Walker
Guest
Posts: n/a
 
      1st Dec 2004
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

"Daniel Moth" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> CreateInstanceFromAndUnwrap is not supported on the CF. I believe you are
> probably out of luck in this area.
>
> Cheers
> Daniel
> --
> http://www.danielmoth.com/Blog/
>
>
> "Chris Walker" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> 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
>>
>>
>>

>
>



 
Reply With Quote
 
Daniel Moth
Guest
Posts: n/a
 
      1st Dec 2004
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
--
http://www.danielmoth.com/Blog/


"Chris Walker" <(E-Mail Removed)> wrote in message
news:e%(E-Mail Removed)...
> 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
>
> "Daniel Moth" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> CreateInstanceFromAndUnwrap is not supported on the CF. I believe you are
>> probably out of luck in this area.
>>
>> Cheers
>> Daniel
>> --
>> http://www.danielmoth.com/Blog/
>>
>>
>> "Chris Walker" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>>> 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
>>>
>>>
>>>

>>
>>

>
>




 
Reply With Quote
 
=?Utf-8?B?cm9ybw==?=
Guest
Posts: n/a
 
      4th Dec 2004
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

"Chris Walker" wrote:

> 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
>
>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can AppDomain be used for non-thread safe component? =?Utf-8?B?U3BsYWtl?= Microsoft Dot NET Framework 0 16th Jul 2007 04:38 PM
Problem with using AppDomain/Assembly Loading in Queued Component xiaohongvz Microsoft Dot NET Framework 0 18th Oct 2006 07:43 PM
How to create 2nd AppDomain? JJ Microsoft Dot NET 1 16th Dec 2004 11:45 AM
Repost: Isolation In AppDomain - How to prevent the main AppDomain to crash when another AppDomain Crashes?????? José Joye Microsoft C# .NET 7 6th Nov 2003 02:10 PM
Repost: Isolation In AppDomain - How to prevent the main AppDomain to crash when another AppDomain Crashes?????? José Joye Microsoft Dot NET 7 6th Nov 2003 02:10 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:37 AM.