HttpModuleAction Class
Represents an ASP.NET module.
Syntax
class HttpModuleAction : CollectionElement
Methods
This class contains no methods.
Properties
The following table lists the properties exposed by the HttpModuleAction
class.
Name | Description |
---|---|
Name |
A read-only string value that specifies the name of an ASP.NET module. The key property. |
Type |
A read/write string value that specifies the type for an ASP.NET module. Note: The type reference is formed as follows (items in brackets are not required): Namespace.Typename, Assemblyname[,] [Version=x,] [Culture=y,] [PublicKeyToken=z] (for example, "ExampleNamespace.ExampleType, Example.Assembly, Version=%ASSEMBLY_VERSION%, Culture=neutral, PublicKeyToken=%MICROSOFT_PUBLICKEY%"). |
Subclasses
This class contains no subclasses.
Remarks
Instances of this class are contained in the HttpModules
property of the HttpModulesSection class.
The modules represented by the HttpModuleAction
class are specific to ASP.NET and are in the <system.web>
section of the Web.config file. These modules are contained in the Modules
array property of the HttpModulesSection class.
The modules represented by the ModuleAction class are IIS 7 related and are in the <system.webServer>
section of the ApplicationHost.config file. These modules are contained in the ModulesSection class.
Example
The following example displays the HttpModuleAction
values that are in the HttpModules
property of the HttpModulesSection
class.
' Connect to the WMI WebAdministration namespace.
Set oWebAdmin = GetObject("winmgmts:root\WebAdministration")
' Get the HttpModulesSection.
Set oSite = oWebAdmin.Get("Site.Name='Default Web Site'")
oSite.GetSection "HttpModulesSection", oSection
' Display the HttpModuleAction instances.
WScript.Echo "------[ Http Modules ]------"
For Each oHttpModule In oSection.HttpModules
WScript.Echo "Name: " & oHttpModule.Name
WScript.Echo "Type: " & oHttpModule.Type
WScript.Echo
Next
Inheritance Hierarchy
HttpModuleAction
Requirements
Type | Description |
---|---|
Client | - IIS 7.0 on Windows Vista - IIS 7.5 on Windows 7 - IIS 8.0 on Windows 8 - IIS 10.0 on Windows 10 |
Server | - IIS 7.0 on Windows Server 2008 - IIS 7.5 on Windows Server 2008 R2 - IIS 8.0 on Windows Server 2012 - IIS 8.5 on Windows Server 2012 R2 - IIS 10.0 on Windows Server 2016 |
Product | - IIS 7.0, IIS 7.5, IIS 8.0, IIS 8.5, IIS 10.0 |
MOF file | WebAdministration.mof |
See Also
CollectionElement Class
HttpModulesSection Class
ModulesSection Class
ModuleAction Class