title: Windows 8 XAML-only solution for toggling the visibility of a control when hovering the mouse over a different control
body: <p>I am working on a project and need help in finding a Windows 8 XAML-only solution for toggling the visibility of a control when hovering the mouse over a different control. The control can be a button or any Windows8 control and the code needs to be in XAML because all my logic is in XAML. 
  I tried numerous XAML solutions but I guess I am missing something. In my first attempt I wrote an event trigger, but string can't be converted into visibility and so the following code crashes when executed.</p>
  
  <p>Can anyone or any expert at Microsoft please help me in this. I really appreciate your help. I am looking for is a solution that does not require any code in the code-behind, it should be complete XAML code. </p>
  
  <pre><code>&lt;Page
      x:Class="App1.MainPage"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:local="using:App1"
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
      mc:Ignorable="d"&gt;
  
      &lt;StackPanel Background="{StaticResource ApplicationPageBackgroundThemeBrush}"&gt;
          &lt;Button Margin="5" x:Name="btn1"&gt;Button 1&lt;/Button&gt;
  
          &lt;Button Margin="5" x:Name="btn2"&gt;
              &lt;Button.Triggers&gt;
                  &lt;EventTrigger RoutedEvent="Button.GotFocus"&gt;
                      &lt;BeginStoryboard&gt;
                          &lt;Storyboard&gt;
                              &lt;DoubleAnimation Storyboard.TargetName="btn1" Storyboard.TargetProperty="Button.Visibility" To="Collapsed" Duration="0:0:1"/&gt;
                          &lt;/Storyboard&gt;
                      &lt;/BeginStoryboard&gt;
                  &lt;/EventTrigger&gt;
  
                  &lt;EventTrigger RoutedEvent="Button.LostFocus"&gt;
                      &lt;BeginStoryboard&gt;
                          &lt;Storyboard&gt;
                              &lt;DoubleAnimation Storyboard.TargetName="btn1" Storyboard.TargetProperty="Button.Visibility" To="Visible" Duration="0:0:1"/&gt;
                          &lt;/Storyboard&gt;
                      &lt;/BeginStoryboard&gt;
                  &lt;/EventTrigger&gt;
              &lt;/Button.Triggers&gt;
              Button 2
          &lt;/Button&gt;
  
          &lt;Button Margin="5" x:Name="btn3"&gt;Button 3&lt;/Button&gt;
  
      &lt;/StackPanel&gt;
  
  &lt;/Page&gt;
  </code></pre>