HttpHandlerActionCollection.Add Method (HttpHandlerAction)
Adds an HttpHandlerAction object to the collection.
Assembly: System.Web (in System.Web.dll)
Parameters
- httpHandlerAction
-
Type:
System.Web.Configuration.HttpHandlerAction
The HttpHandlerAction object to add to the collection.
| Exception | Condition |
|---|---|
| ConfigurationException | The HttpHandlerAction object to add already exists in the collection or the collection is read-only. |
Before using this method you must create an HttpHandlerAction object and initialize it with the proper name and type. After that, you can add the object just created to the collection.
Note |
|---|
ASP.NET searches for the handler assembly DLL in the application's private Bin directory first, and then it searches in the system assembly cache. |
The collection must not already contain an HttpHandlerAction object with the same Verb and Path properties.
The following code example shows how to create an HttpHandlerAction object and add it to the collection.
Available since 2.0
