Rule Collection. Remove(AuthorizationRule) Method
Removes a AuthorizationRule object from the collection.
public: void Remove(System::Web::Configuration::AuthorizationRule ^ rule);
public void Remove (System.Web.Configuration.AuthorizationRule rule);
member this.Remove : System.Web.Configuration.AuthorizationRule -> unit
Public Sub Remove (rule As AuthorizationRule)
The passed AuthorizationRule object does not exist in the collection, the element has already been removed, or the collection is read-only.
// Remove the rule from the collection. authorizationSection.Rules.Remove(authorizationRule);
' Remove the rule from the collection. authorizationSection.Rules.Remove(authorizationRule)
This method inserts a
remove element into the appropriate section of the configuration file for any element defined in a higher-level configuration file. If the element is defined in the appropriate section of the current configuration file, its entry is removed from the configuration file. The object to remove must exist in the collection.