AuthorizationRuleCollection.Set(Int32, AuthorizationRule) Método
Definição
Importante
Algumas informações dizem respeito a um produto pré-lançado que pode ser substancialmente modificado antes de ser lançado. A Microsoft não faz garantias, de forma expressa ou implícita, em relação à informação aqui apresentada.
Adiciona o objeto especificado AuthorizationRule à coleção no índice especificado.
public:
void Set(int index, System::Web::Configuration::AuthorizationRule ^ rule);
public void Set(int index, System.Web.Configuration.AuthorizationRule rule);
member this.Set : int * System.Web.Configuration.AuthorizationRule -> unit
Public Sub Set (index As Integer, rule As AuthorizationRule)
Parâmetros
- index
- Int32
A localização do índice onde adicionar o objeto especificado AuthorizationRuleCollection .
- rule
- AuthorizationRule
O AuthorizationRule objeto a acrescentar.
Exemplos
O exemplo de código a seguir mostra como usar o Set método.
// Using the AuthorizationRuleCollection Set method.
// Define the rule to add to the collection.
// Define the collection index.
System.Int32 rIndex = 0;
// Set the rule in the collection.
authorizationRuleCollection.Set(rIndex,
authorizationRule);
' Using the AuthorizationRuleCollection Set method.
' Define the rule to add to the collection.
' Define the collection index.
Dim rIndex As System.Int32 = 0
' Set the rule in the collection.
authorizationRuleCollection.Set(rIndex, _
authorizationRule)