title: How do I change the image when the button is disabled?
body: <p>I'm trying to show a different image when the button is disabled; I thought it would be easy with triggers.</p>
  
  <p>However, I have not been able to get the image source to switch to the disabled image when the button is disabled. I've tried setting triggers on both the image and button.  What is wrong with what I have below? How can I change the image source when the button is enabled/disabled?</p>
  
  <pre><code>&lt;Button
           x:Name="btnName"
           Command="{Binding Path=Operation}"
           CommandParameter="{x:Static vm:Ops.OpA}"&gt;
              &lt;Button.Content&gt;
                  &lt;StackPanel&gt;
                      &lt;Image
                    Width="24"
                    Height="24"             
                    RenderOptions.BitmapScalingMode="NearestNeighbor"
                    SnapsToDevicePixels="True"
                    Source="/MyAssembly;component/images/enabled.png"&gt;
                          &lt;Image.Style&gt;
                              &lt;Style&gt;
                                  &lt;Style.Triggers&gt;
                                      &lt;DataTrigger Binding="{Binding ElementName=btnName, Path=Button.IsEnabled}" Value="False"&gt;
                                          &lt;Setter Property="Image.Source" Value="/MyAssembly;component/images/disabled.png" /&gt;
                                      &lt;/DataTrigger&gt;
                                  &lt;/Style.Triggers&gt;
                              &lt;/Style&gt;
                          &lt;/Image.Style&gt;
                      &lt;/Image&gt;
                  &lt;/StackPanel&gt;
              &lt;/Button.Content&gt;
          &lt;/Button&gt;
  </code></pre>