title: Finding the Content of a ContentPresenter and setting styles
body: <p>I couldn't find an appropriate topic for my problem. I have the following code.</p>
  
  <pre><code>&lt;ContentPresenter x:Name="ContentPresenter"
                    VerticalAlignment="Center"                      
                    Width="Auto"/&gt;
  &lt;TextBox x:Name="TextBlockFront" &gt;
      &lt;TextBox.Style&gt;
          &lt;Style TargetType="TextBox"&gt;
              &lt;Style.Triggers&gt;
                  &lt;MultiDataTrigger&gt;
                      &lt;MultiDataTrigger.Conditions&gt;
                      &lt;Condition Binding="{Binding ElementName=TextBlockFront, Path=IsFocused}" Value="true"/&gt;
                      &lt;Condition Binding="{Binding ElementName=ContentPresenter, Path=ContentProperty}" Value="ComboBox"/&gt;
                      &lt;/MultiDataTrigger.Conditions&gt;
                      &lt;Setter Property="Visibility" Value="Hidden"/&gt;
                      &lt;Setter Property="Text" Value="{Binding ElementName=ContentPresenter,Path=SelectedItem}"/&gt;
                  &lt;/MultiDataTrigger&gt;
              &lt;/Style.Triggers&gt;
          &lt;/Style&gt;
      &lt;/TextBox.Style&gt;
  &lt;/TextBox&gt;
  </code></pre>
  
  <p>I want to get the clarification about the second condition of my <code>MultiTrigger</code>. I am relative new to WPF and I would appreciate any help in sorting out my doubt.</p>
  
  <p>Expected behaviour:</p>
  
  <p>when the <code>TextBox</code> is focused <strong>AND</strong> the <code>ContentPresenter</code> is <code>ComboBox</code> then I want to set the above properties. If the <code>ContentPresenter</code> is <code>TextBox</code> then I will set the <code>Text</code> property instead of <code>SelectedItem</code></p>