HttpModuleAction.Name Property

 

Gets or sets the module name.

Namespace:   System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)

[ConfigurationPropertyAttribute("name", IsRequired = true, IsKey = true, 
	DefaultValue = "")]
[StringValidatorAttribute(MinLength = 1)]
public string Name { get; set; }

Property Value

Type: System.String

The module name.

The module name is used to identify this HttpModuleAction object.

The following code example shows how to use the Name property.


// Get the modules collection.
HttpModuleActionCollection httpModules = 
    httpModulesSection.Modules;
string moduleFound = "moduleName not found.";

// Find the module with the specified name.
foreach (HttpModuleAction currentModule in httpModules)
{
    if (currentModule.Name == "moduleName")
        moduleFound = "moduleName found.";

}

.NET Framework
Available since 2.0
Return to top
Show: