ClientTargetCollection.RemoveAt(Int32) Metod
Definition
Viktigt
En del information gäller för förhandsversionen av en produkt och kan komma att ändras avsevärt innan produkten blir allmänt tillgänglig. Microsoft lämnar inga garantier, uttryckliga eller underförstådda, avseende informationen som visas här.
Tar bort objektet med det angivna samlingsindexet ClientTarget .
public:
void RemoveAt(int index);
public void RemoveAt(int index);
member this.RemoveAt : int -> unit
Public Sub RemoveAt (index As Integer)
Parametrar
- index
- Int32
Samlingsindexet för att ClientTarget ta bort.
Exempel
Följande kodexempel tar ClientTarget bort objektet från ClientTargetCollection samlingen.
Information om hur du hämtar samlingen finns i kodexemplet i klassöversikten ClientTargetCollection .
// Remove the client target at the
// specified index from the collection.
clientTargets.RemoveAt(0);
// Update the configuration file.
if (!clientTargetSection.IsReadOnly())
configuration.Save();
' Remove the client target at the
' specified index from the collection.
clientTargets.RemoveAt(0)
' Update the configuration file.
If Not clientTargetSection.IsReadOnly() Then
configuration.Save()
End If
Kommentarer
Metoden RemoveAt tar bort elementet addclientTarget i avsnittet på den aktuella hierarkinivån och infogar ett remove element. Elementet remove tar effektivt bort referensen till elementet add som definierats i de överordnade konfigurationsfilerna på högre nivåer i hierarkin men tar inte bort det.