title: Two Dimensional Array VB
body: <p>Ok so I am having problems adding elements into my 2d array.  I am using 3 textboxes to allow a user to input items into my array. My problem is I cant seem to get the array to go past (0,2). I want the user to be able to add a row of inputs with each click of the add button. This is so far what I have in my code. Can anyone help? This is not for a class I am learning on my own.</p>
  
  <pre><code>Option Strict On
  Option Explicit On
  Option Infer Off
  
  Public Class Form1
  
  Private strExams(49, 2) As String
  
  Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
  
      Dim strStudent As String = txtStudent.Text
      Dim strTest As String = txtTest.Text
      Dim strScore As String = txtScore.Text
      Dim count As Integer = 0
  
      If count &lt;= 49 Then
          strExams(count, 0) = strStudent
          strExams(count, 1) = strTest
          strExams(count, 2) = strScore
          count += 1
      End If
  
      txtStudent.Text = String.Empty
      txtTest.Text = String.Empty
      txtScore.Text = String.Empty
  
      txtStudent.Focus()
  
  End Sub
  </code></pre>