System.AppDomainSetup.DynamicBase Property

Gets or sets the base directory where the directory for dynamically generated files is located.

Syntax

public string DynamicBase { get; set; }

Value

Documentation for this section has not yet been entered.

Remarks

Use this property to set the base directory where the dynamic directory for the new application domain will be located. When code in the new application domain loads an assembly, assembly resolution looks first in the normal probing paths. If it does not find the assembly, it looks in the dynamic directory, which is returned by the AppDomain.DynamicDirectory property. Dynamic assemblies that will be loaded and executed by the new application domain can be placed there.

When you assign a path to the AppDomainSetup.DynamicBase property, an additional subdirectory is added; the name of this subdirectory is the hash code of the value assigned to the AppDomainSetup.ApplicationName property. Thus, the base directory subsequently returned by this property is always different from the value assigned.

Note:

Assigning a value to this property does not create any directories. The directories must be created or verified by the code that uses them.

The dynamic directory is a subdirectory of AppDomainSetup.DynamicBase. Its simple name is the value returned by the AppDomainSetup.ApplicationName property, so its format is original path\hash code\application name.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0