title: ComboBox SelectedValue or SelectedItem Binding WPF C#
body: <p>I have a combobox that is binding to an <code>ObservableCollection</code> of strings in an object. This binding works, but I also want to bind whatever the user selects from this combobox, in a different property which is a string, in the same Object.  I cannot figure out whether I should use <code>SelectedValue</code> or <code>SelectedItem</code>, or if there is a problem beyond that.  Thank you in advance.  </p>
  
  <p>Here is what I have so far, I have omitted any code irrelevant to the problem:</p>
  
  <p><strong>In XAML:</strong></p>
  
  <pre><code>&lt;Grid.Resources&gt;
      &lt;my:JobItem x:Key="jobItemViewSource" /&gt;
  &lt;/Grid.Resources&gt;
  
  &lt;ComboBox x:Name="businessUnitBox" ItemsSource="{Binding Path=BusinessUnits}" IsSynchronizedWithCurrentItem="True"&gt;
      &lt;ComboBox.SelectedValue&gt;
          &lt;Binding Path="BusinessUnit" Mode="TwoWay" UpdateSourceTrigger="Explicit" /&gt;
      &lt;/ComboBox.SelectedValue&gt;
  &lt;/ComboBox&gt;
  </code></pre>
  
  <p><strong>Code behind:</strong></p>
  
  <pre><code>public string BusinessUnit
  {
      get{  return businessUnit; }
      set
      {
          if (String.IsNullOrEmpty(BusinessUnit) || !BusinessUnit.Equals(value))
          {
              businessUnit = value;
              OnPropertyChanged("BusinessUnit");
          }
      }
  
  }
  
  public ObservableCollection&lt;string&gt; BusinessUnits
  {
      get { return businessUnits; }
      set
      {
          if(!BusinessUnits.Equals(value))
          {
              businessUnits = value;
              OnPropertyChanged("BusinessUnits");
          }
  
          businessUnits = value;
      }
  }
  </code></pre>