Csharp/CSharp Tutorial/Assembly/AppDomainSetup

Материал из .Net Framework эксперт
Перейти к: навигация, поиск

Configure the application domain setup information

using System;
class MainClass
{
    public static void Main()
    {
        AppDomainSetup setupInfo = new AppDomainSetup();

        setupInfo.ApplicationBase = @"C:\MyRootDirectory";
        setupInfo.ConfigurationFile = "MyApp.config";
        setupInfo.PrivateBinPath = "bin;plugins;external";
        AppDomain newDomain = AppDomain.CreateDomain("My New AppDomain", null, setupInfo);
    }
}