title: Wpf Combobox selectedvalue trigger
body: <p>I am trying to change the visibility with a trigger when a particular value in a combobox is selected, and I got the following XAML</p>
  
  <pre><code> &lt;ItemsControl ItemsSource="{Binding AccessControl.Credentials}" &gt;
                          &lt;ItemsControl.ItemTemplate&gt;
                          &lt;DataTemplate&gt;                              
                              &lt;Grid  &gt;                                  
  
                               &lt;ComboBox  Name="chkFieldType"                                          
                                          SelectedValue="{Binding Path=ValueSourceType,Converter={StaticResource enumstringConv}}"
                                          SelectedValuePath="Tag" SelectionChanged="chkFieldType_SelectionChanged" &gt;
                                             &lt;ComboBoxItem Tag="User"&gt;User&lt;/ComboBoxItem&gt;                                     
                                             &lt;ComboBoxItem Tag="SessionCredential"&gt;Field&lt;/ComboBoxItem&gt;
                                             &lt;ComboBoxItem Tag="Inherit"&gt;From other Resource&lt;/ComboBoxItem&gt;
                               &lt;/ComboBox&gt;
  
  
                                      &lt;Border " Visibility="Hidden"&gt;
                                          &lt;Border.Resources&gt;
                                              &lt;Style TargetType="{x:Type Border}"&gt;
                                                  &lt;Style.Triggers&gt;
                                                      &lt;DataTrigger Binding="{Binding Path=SelectedValue, ElementName=chkFieldType}" Value="Inherit"&gt;
                                                          &lt;Setter Property="Visibility" Value="Visible" /&gt;
                                                      &lt;/DataTrigger&gt;
                                                  &lt;/Style.Triggers&gt;
                                              &lt;/Style&gt;
                                          &lt;/Border.Resources&gt;
                                          &lt;ComboBox/&gt;                                         
                                      &lt;/Border&gt;
  </code></pre>
  
  <p>In this case a border. The selected value is "Inherit" of type string but the border remainds hidden. </p>