KC,
It's like adding any other item to an ArrayList, and then retrieving
that.
For example, if you wanted to add a Hashtable to an ArrayList, then you
would do this:
// An array list.
ArrayList arrayList = new ArrayList();
// Add 100 hashtables.
for (int index = 0; index < 100; index++)
{
// Add a hashtable.
arrayList.Add(new Hashtable());
}
Now if you want to use one of the hashtables, you would have to cast the
item that the array list returns:
// Get the first hashtable.
Hashtable hashTable = (Hashtable) arrayList[0];
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Netmonster" <ne***********@yahoo.com> wrote in message
news:11*********************@f14g2000cwb.googlegro ups.com...
Hello,
Does any one have an example of how to create an ArrayList of objects?
i.e. ArrayList of ArrayLists or an ArrayList of Hashtables?
Thanks in advance
KC