C# HybridDictionary Remove
Description
HybridDictionary Remove
removes the entry with the specified
key from the HybridDictionary.
Syntax
HybridDictionary.Remove
has the following syntax.
public void Remove(
Object key
)
Parameters
HybridDictionary.Remove
has the following parameters.
key
- The key of the entry to remove.
Returns
HybridDictionary.Remove
method returns
Example
using System;/*from w w w . j a v a 2 s .co m*/
using System.Collections;
using System.Collections.Specialized;
public class SamplesHybridDictionary {
public static void Main() {
HybridDictionary myCol = new HybridDictionary();
myCol.Add( "F", "1.49" );
myCol.Add( "A", "1.29" );
myCol.Add( "B", "1.49" );
myCol.Remove( "S" );
foreach ( DictionaryEntry de in myCol )
Console.WriteLine( " {0,-25} {1}", de.Key, de.Value );
}
}
The code above generates the following result.