title: Adding Items to a ListBox
body: <p>I have a WPF main window, which contains a toolbar with buttons and a tabcontrol that is displaying a page with a listbox. The page is hosted on a frame, and the frame is set on the tab I selected.</p>
  
  <p>When I click on a button on my toolbar, a new window pops up with a textbox and a submit button. When I press the submit button, I want to insert the textbox contents into the listbox that's on the main window. However, nothing displays in the listbox. I tried listbox.Items.Add() but it still won't display.</p>
  
  <pre><code>public partial class AddNewCamper : Window
  {
      public AddNewCamper()
      {
          InitializeComponent();
      }
  
      private void btnNewSubmit_Click(object sender, RoutedEventArgs e)
      {
          CampersPage c;
  
          // Converting string to int b/c thats what camper() takes in.
          int NewAge = Convert.ToInt16(txtNewAge.Text);
          int NewGrade = Convert.ToInt16(txtNewGrade.Text);
  
          // Create a new person
          Camper person = new Camper(NewAge, NewGrade, txtNewFirstName.Text);
          txtNewFirstName.Text = person.getName();
  
          // Trying to add the first name of the person to display on the listbox of another window.
          c.testListBox.Items.Add(txtNewFirstName.Text);
      }
  </code></pre>