I need something like an hashtable that let me get objects by its name but that also lets me loop through them. Does it even exist? Thanks
I need something like an hashtable that let me get objects by its name but that also lets me loop through them. Does it even exist? Thanks
Hope I understand you correctly, PT Exorcist. Can't you "loop through" the Hashtable with a For Each...? Hashtable implements ICollection.
I have some code that looks like this:
VB Code:
For Each de As DictionaryEntry In serverSockets 'serverSockets is a Hashtable . . . Next
HTH,
Mike
If you're not happy with hashtable then why don't you just create your own custom class and make it iteratable .
edit : or you can wait until MS release VS.NET 2005 , where custom classes are iteratable easily (just couple of steps, as I heard) ..:D
Well I was asking if it *already* exists. Of course I can create one of my own but that would be wasting my time if it already exists.
But I didnt remember I could use a foreach loop :afrog: