title: Label content in custom UserControl not updating
body: <p>I've created a custom UserControl which consists of 12 labels.  </p>
  
  <p><img src="https://i.stack.imgur.com/rMIpS.png" alt="enter image description here"></p>
  
  <p>Now, when the program loads, the labels with "Default" as the content need to be changed.</p>
  
  <pre><code>// This is called in my main forms constructor, right before InitializeComponent()
  public void ShowRigInfo()
  {
      // This is here because if I try to call PopluateLabels, I get an "Object not
      // set to an instance of object" error
      grdRigInfo = new RigInfoGrid();
  
      var contractor = SplitString("contractor", _rigInfo);
      var projectName = SplitString("projectname", _rigInfo);
      var location = SplitString("location", _rigInfo);
      var operatorName = SplitString("operator", _rigInfo);
      var rigName = SplitString("rigsite_name", _rigInfo);
      var rigManager = SplitString("rigmanager", _rigInfo);
  
      grdRigInfo.PopulateLabels(contractor, projectName, location, operatorName,
                                rigName, rigManager);
      }
  
  // A public method of my custom UserControl to update label content
  public void PopulateLabels(string contractor, string project, string location, 
                             string operatorName, string rigName, string manager)
  {
      lblContractor.Content = contractor;
      lblProjectName.Content = project;
      lblLocation.Content = location;
      lblOperator.Content = operatorName;
      lblRigName.Content = rigName;
      lblRigManager.Content = manager;            
  }
  </code></pre>
  
  <p>My question is, how can I get the labels to update upon program start up?  Thanks for any and all help.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I have tried to call <code>ShowRigInfo()</code> both before and after <code>InitializeComponent()</code> of my main form.  Neither of them changed the labels.</p>
  
  <p><strong>EDIT 2</strong></p>
  
  <p>Okay, I solved this before I actually saw the answers.  What I did was moved my <code>ShowRigInfo()</code> into my custom UserControl, instead of my main form.  I don't know why I didn't do that from the start, but there it is.  I'll be looking into the DataBinding portion of the answers.  Thank you guys.</p>