Udostępnij za pośrednictwem


remove Element for assemblies for compilation (ASP.NET Settings Schema)

Removes a reference to an inherited assembly name from the collection.

<configuration> Element
  system.web Element (ASP.NET Settings Schema)
    compilation Element (ASP.NET Settings Schema)
      assemblies Element for compilation (ASP.NET Settings Schema)
        remove Element for assemblies for compilation (ASP.NET Settings Schema)

<remove 
   assembly="assembly"
/>

Attributes and Elements

The following sections describe attributes, child elements, and parent elements.

Attributes

Attribute

Description

assembly

Required String attribute.

Specifies the name of the assembly to remove from the collection. The format is a comma-separated assembly combination consisting of version, culture, and public key tokens. This string should match the assembly attribute of the add element that is in the configuration file where the assembly was added.

Child Elements

None.

Parent Elements

Element

Description

configuration

Specifies the required root element in every configuration file that is used by the common language runtime and the .NET Framework applications.

system.web

Specifies the root element for the ASP.NET configuration section.

compilation

Configures all compilation settings that ASP.NET uses to compile applications.

assemblies

Defines a collection of names of assemblies that are used during compilation of an ASP.NET application.

Remarks

The remove element removes a reference to an inherited assembly name from the collection that is contained in the assemblies element.

The assemblies element defines a collection of names of assemblies that are used during compilation of an ASP.NET application.

Example

The following code example demonstrates how to configure compilation settings for an application.

<configuration>
   <system.web>
      <compilation defaultLanguage="VB">
         <assemblies>
            <remove assembly="ADODB"/>
            <remove assembly="*"/>
         </assemblies>
      </compilation>
   </system.web>
</configuration>

Element Information

Configuration section handler

CompilationSection

Configuration member

Remove

Configurable locations

Machine.config

Root-level Web.config

Application-level Web.config

Virtual or physical directory–level Web.config

Requirements

Microsoft Internet Information Services (IIS) version 5.0, 5.1, or 6.0

The .NET Framework version 1.0, 1.1, or 2.0

Microsoft Visual Studio 2003 or Visual Studio 2005

See Also

Tasks

How to: Configure Specific Directories Using Location Settings

How to: Lock ASP.NET Configuration Settings

Reference

assemblies Element for compilation (ASP.NET Settings Schema)

add Element for assemblies for compilation (ASP.NET Settings Schema)

clear Element for assemblies for compilation (ASP.NET Settings Schema)

configuration Element (General Settings Schema)

system.web Element (ASP.NET Settings Schema)

compilation Element (ASP.NET Settings Schema)

System.Configuration

System.Web.Configuration

CompilationSection

Remove

Concepts

ASP.NET Compilation Overview

ASP.NET Web Page Syntax Overview

ASP.NET Configuration File Hierarchy and Inheritance

Securing ASP.NET Configuration

ASP.NET Configuration Scenarios

Other Resources

General Configuration Settings (ASP.NET)

ASP.NET Configuration Settings

ASP.NET Web Site Administration

ASP.NET Configuration Files

ASP.NET Configuration API