PC Review


Reply
Thread Tools Rate Thread

AppDomain Probing

 
 
A. Elamiri
Guest
Posts: n/a
 
      15th Jul 2004
Hello,

I created a small app which acts as a services manager. I basically drop a
DLL in a Services folder and set the frequency through the application for
how often do I want the code in the assembly to run (scheduler).

I created a seperate AppDomain here is the code:
....
AppDomainSetup ads = new AppDomainSetup();
string path =
Application.ExecutablePath.Replace(System.IO.Path.GetFileName(Application.Ex
ecutablePath),"");
ads.ApplicationBase = path + "Services";
ads.PrivateBinPathProbe = path + "Services";
ads.PrivateBinPath = path + "Services";
ads.DisallowBindingRedirects = true;
Tools.ShowInfo(path);
SvcBin = AppDomain.CreateDomain("ServiceAssemblies",null,ads);

....

The above code was placed in the constructor. When I look through the
assemblies (GetAssemblies) to see a listing of all classes loaded, I don't
see the classes in the dll located in that services folder, which made me
think that it is not being probed. Anything I'm doing wrong?
--
Abdellah Elamiri
..net Developer
Efficacy through simplicity


 
Reply With Quote
 
 
 
 
A. Elamiri
Guest
Posts: n/a
 
      16th Jul 2004
yeah it's true... I didn't know that

--
Abdellah Elamiri
..net Developer
Efficacy through simplicity
"Anna" <(E-Mail Removed)> wrote in message
news:C0416C10-6235-42C4-A0CD-(E-Mail Removed)...
> Hi,
>
> I am maybe wrong on this one by I thought the assembly doesn't accually

get loaded untill you excetute methond on one of its types. I thought that
was the whole point of even if you have a lot of assemblies referenced in
your app not all of them will be loaded upon app start.
>
> What do you think?
>
> Anna
>
> "A. Elamiri" wrote:
>
> > Hello,
> >
> > I created a small app which acts as a services manager. I basically drop

a
> > DLL in a Services folder and set the frequency through the application

for
> > how often do I want the code in the assembly to run (scheduler).
> >
> > I created a seperate AppDomain here is the code:
> > ....
> > AppDomainSetup ads = new AppDomainSetup();
> > string path =
> >

Application.ExecutablePath.Replace(System.IO.Path.GetFileName(Application.Ex
> > ecutablePath),"");
> > ads.ApplicationBase = path + "Services";
> > ads.PrivateBinPathProbe = path + "Services";
> > ads.PrivateBinPath = path + "Services";
> > ads.DisallowBindingRedirects = true;
> > Tools.ShowInfo(path);
> > SvcBin = AppDomain.CreateDomain("ServiceAssemblies",null,ads);
> >
> > ....
> >
> > The above code was placed in the constructor. When I look through the
> > assemblies (GetAssemblies) to see a listing of all classes loaded, I

don't
> > see the classes in the dll located in that services folder, which made

me
> > think that it is not being probed. Anything I'm doing wrong?
> > --
> > Abdellah Elamiri
> > ..net Developer
> > Efficacy through simplicity
> >
> >
> >



 
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
AppDomain and probing Boni Lopez Microsoft C# .NET 0 30th Apr 2007 10:01 PM
HELP: how to find list of AppDomain under main process appdomain Hank Microsoft Dot NET Framework 1 17th Sep 2005 04:55 AM
AppDomain Probing issue A. Elamiri Microsoft C# .NET 8 16th Jul 2004 03:19 PM
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 12:48 PM.