Muokkaa

Jaa


<assemblyBinding> element for <configuration>

Specifies assembly binding policy at the configuration level.

<configuration>
  <assemblyBinding>

Syntax

<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
  <!-- Configuration files to include. -->
</assemblyBinding>

Attribute

Description
xmlns Required attribute.

Specifies the XML namespace required for assembly binding. Use the string "urn:schemas-microsoft-com:asm.v1" as the value.

Parent element

Description
<configuration> The root element in every configuration file used by the common language runtime and .NET Framework applications.

Child element

Description
<linkedConfiguration> Specifies a configuration file to include.

Remarks

The <linkedConfiguration> element simplifies the management of component assemblies by allowing application configuration files to include assembly configuration files in well-known locations, rather than duplicating assembly configuration settings.

Note

The <linkedConfiguration> element is not supported for applications with Windows side-by-side manifests.

Example

The following example shows how to include a configuration file on the local hard disk:

<configuration>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
    <linkedConfiguration href="file://c:\Program Files\Contoso\sharedConfig.xml" />
  </assemblyBinding>
</configuration>

See also