title: How to add to end of array C#?
body: <p>How do I add a new <code>item</code> from a TextBox and Button on a Windows Form at the end of an <code>ArrayList</code> which references a class?</p>
  
  <pre><code>private product[] value = new product[4];
  
  value[1] = new product("One",5)
  value[2] = new product("Two",3)
  value[3] = new product("Three",8)
  </code></pre>
  
  <h3>Workflow</h3>
  
  <ul>
  <li>Enter new products details into <code>textbox1</code>, <code>textbox2</code>, <code>textbox3</code> </li>
  <li><p>When I click <code>Add</code> the new product gets added to the array:</p>
  
  <p><code>value[1] = new product("One",5)</code><br>
  <code>value[2] = new product("Two",3)</code><br>
  <code>value[3] = new product("Three",8)</code><br>
  <code>value[4] = new product("Four",2)</code>  </p></li>
  </ul>
  
  <p>What is the code for doing this?</p>