title: how to access a dynamically generated textbox in a form from other parts of the program?
body: <p>i currently have a form which i dynamically created a 2D array of textboxes, buttons etc. i just found out my other parts of the program cannot access to the textboxes i created? is there a way i can do it?</p>
  
  <p>my codes goes something like:</p>
  
  <pre><code>    public Form1()
      {
          int column = 4;
  
          System.Windows.Forms.TextBox[,] textbox = new System.Windows.Forms.TextBox[column, row];
  
          for (int i = 0; i &lt; column; i++)
          {
              for (int j = 0; j &lt; row; j++)
              {
                  textbox[i, j] = new System.Windows.Forms.TextBox();
                  textbox[i, j].Size = new Size(80, 20);
                  textbox[i, j].Name = "textbox_" + i + "_" + j;
                  textbox[i, j].Location = new System.Drawing.Point((i * 80) + 20, (j * 20) + 30);
                  textbox[i, j].Visible = true;
                  Controls.Add(textbox[i, j]);
  
              }
          }
  
          /////fill the textboxes with data//////
      }
  </code></pre>
  
  <p>i cannot access the textbox outside the method, how can i do it? can you provide some working coded? i am still relatively new to c#, thank you very much</p>