title: I cant pass my array variable to another form in winform c#
body: <p>I declared my array like this <code>string[] dateArray = new string[10];</code> then placing a value to it like this:</p>
  
  <pre><code>public void btnAdd_Click(object sender, EventArgs e)
  {
  dateArray[i] = date.Text.ToString();
  }
  </code></pre>
  
  <p>So far, after a few inputs and want to check if it the <code>dateArray</code> has a value I did this. </p>
  
  <pre><code>private void button1_Click(object sender, EventArgs e)
  {
   string toDisplay = string.Join(Environment.NewLine, dateArray);
   MessageBox.Show(toDisplay);
  }
  </code></pre>
  
  <p>And it is really have a value and displaying it. <br>
  So I've created a button that may pass the value of <code>dateArray</code> to another form for it to display and print. I'm using iTextSharp. Here is my button:</p>
  
  <pre><code>  public static string finalDate;
    private void printBtn_Click(object sender, EventArgs e)
          {
             string finalDate = string.Join(Environment.NewLine, dateArray);
              printForm table_form = new printForm();
              table_form.Show();
          }
  </code></pre>
  
  <p>And passing the string <code>finalDate</code>(Second form) to here</p>
  
  <pre><code> table2.AddCell(new Phrase(tableITS.finalDate, data));
  </code></pre>
  
  <p>But no luck, I tried putting a message box at the end of <code>doc.Close();</code> but it really doesn't have a value </p>
  
  <pre><code> MessageBox.Show(tableITS.finalDate);
  </code></pre>
  
  <p>What am I getting wrong?
  EDIT: <br>
  I'm passing it here </p>
  
  <pre><code>private void printForm_Load(object sender, EventArgs e)
  {
  string finalDate2 = tableITS.finalDate;
  .
  .
  .
  //Document printing stuff
  }
  </code></pre>