封裝每個議會的具約束力政策及集會地點。 每個組件只用一個 dependentAssembly 元素。
<組態>
<運行時間>
<assemblyBinding>
<dependentAssembly>
語法
<dependentAssembly>
</dependentAssembly>
屬性和項目
下列章節說明屬性、子元素和父元素。
Attributes
沒有。
子元素
| 元素 | Description |
|---|---|
assemblyIdentity |
包含關於該組裝的識別資訊。 這個元素必須包含在每個 dependentAssembly 元素中。 |
codeBase |
指定執行時若未安裝於電腦上的共用組件,該執行時可在哪裡找到。 |
bindingRedirect |
將一個組合語言版本導向到另一個組合語言版本。 |
publisherPolicy |
指定執行時是否對此組合應用發佈者政策。 |
父項目
| 元素 | Description |
|---|---|
assemblyBinding |
包含關於組合語言版本重定向及組裝檔位置的資訊。 |
configuration |
通用語言執行平台和 .NET Framework 應用程式所使用之每個組態檔中的根項目。 |
runtime |
包含關於組裝裝訂與垃圾回收的資訊。 |
Example
以下範例展示了如何封裝兩個組件的組裝資訊。
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="myAssembly"
publicKeyToken="32ab4ba45e0a69a1"
culture="neutral" />
<!--Redirection and codeBase policy for myAssembly.-->
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="mySecondAssembly"
publicKeyToken="32ab4ba45e0a69a1"
culture="neutral" />
<!--Redirection and codeBase policy for mySecondAssembly.-->
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>