I cannot seem to even get started using an ArrayList using Visual Studio 2005. The dot operator does not provide the methods explained in the book I have like "add", "clear", etc....
If I use "private ArrayList ab = new ArrayList(5);" below then I get "No overload for method 'ArrayList' takes '1' arguments" compile error!
What am I doing wrong?
Code:using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Windows.Forms; namespace ArrayList { public partial class ArrayList : Form { private ArrayList ab = new ArrayList(); public ArrayList() { InitializeComponent(); } private void ArrayList_Load(object sender, EventArgs e) { // ab.add("Test"); -- This .add method is not allowed by the studio - Why? } // end Load } // end partial class } // end namespace ArrayList



LinkBack URL
About LinkBacks


