> And to follow up a little more, the dynamically-created AppDomain
> (which lives in a seperate assembly in a discrete standalone .dll) is
AppDomains 'live' in processes, not in .dlls. As long as the hosting process
is alive, so is the AppDomain.
> called from global.asax in an ASP.NET application. But when IIS is
> restarted, the appdomain does not go away, so the .dll cannot be
> deleted.
Looks like IIS restart does not force the ASP .NET working process to
restart. I am not sure how one could ensure automatic restart though. You
can try configuring your Web application to run within the IIS process, but
again, I am not sure this has effect on ASP .NET - I haven't done ASP .NET
for more than half a year.

Signature
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx
> And to follow up a little more, the dynamically-created AppDomain
> (which lives in a seperate assembly in a discrete standalone .dll) is
[quoted text clipped - 4 lines]
>
> Thanks.
This link answers many of your appdomain questions.
http://www.gotdotnet.com/team/clr/AppdomainFAQ.aspx
If the appdomain you created is done so within the context of of an ASP.NET
app, and if this app is loaded by IIS, then resetting IIS will unload all
the secondary appdomains running within its worker process. If the DLL is
locked then something else is loading it. There must be something else going
on here.
> And to follow up a little more, the dynamically-created AppDomain
> (which lives in a seperate assembly in a discrete standalone .dll) is
[quoted text clipped - 4 lines]
>
> Thanks.