"Collection" of objects in C#
I am trying to convert a program from VB6 into C#.NET. The VB6 code uses a very usful thing called a "collection" where you can simply add an object to it without defining the collection type. It may be a really obvious answer, but is there a similar system in C#. I looked at ArrayList but the problem with that is I can't do myArray[x].objectMethod();" for example. I want to add the object of same type to an array but at the same time, be able to reference the attributes and methods of the objects directly.