I would like to figure out how to change a Border’s BorderColor with MouseOver the StackPanel that is inside it. I have tried by setting the TargetName to the name of the border inside of the StackPanel’s VSM. I know I am way off, but I rather try something…
<Border x:Name="LinksBorder" >
<StackPanel x:Name="LinksStackPanel" Margin="10" Orientation="Horizontal" FlowDirection="RightToLeft" HorizontalAlignment="Center" Width="311">
<VisualStateManager.VisualStateGroups>
<VisualStateGroup x:Name="CommonStates">
<VisualState x:Name="Normal">
</VisualState>
<VisualState x:Name="MouseOver">
<Storyboard>
<ColorAnimation
Duration="0" Storyboard.TargetName="LinksBorder" Storyboard.TargetProperty="(BorderBrush).(SolidBrush)" To="#FF0000" />
</Storyboard>
</VisualState>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
My workaround:
Still like to see the other way too…