Hashtable, ArrayList etc.

Feb 18 2004 1:34 PM
I use hashtable to store my objects in memory. Now what i am finding out is that there is a convinient .Add() method but no .Get method. Everytime i need my object i have to get the IDictionaryEnumerator by using .GetEnumerator() method and then loop thru to find my object. Samething applies for ArrayList. Pls. help 'cause the looping code is ugly and i am sure it will effect the performance. Is there a better way other than looping?? OR a better way to store objects in memory.

Answers (1)