Posts
337
Comments
125
Trackbacks
5
Hashtables lassen sich auf 3 Wegen ausgeben

Fürs Archiv:

Hashtables lassen sich auf 3 Wegen ausgeben:

Möglichkeit a)

Hashtable tableDefaultValues = new Hashtable();

IDictionaryEnumerator enumeratorDefaultValues = tableDefaultValues.GetEnumerator();

while (enumeratorDefaultValues.MoveNext()) {

 

}

Möglichkeit b)

Hashtable tableDefaultValues = new Hashtable();

foreach (DictionaryEntry entry in tableDefaultValues) {

 

}

Möglichkeit c)

Hashtable tableDefaultValues = new Hashtable();

foreach (object key in tableDefaultValues .Keys)

{

}

 

posted on Friday, November 21, 2008 11:12 AM Print
Comments
No comments posted yet.

Post Comment

Title *
Name *
Email
Url
Comment *  
Please add 2 and 8 and type the answer here: