WPF Border IsMouseOver trigger not working
Its because you have set the Background
in the Border
, this will override the Style
You will have to remove Background="#FF801F1F"
from the Border
xaml
so the Style
can set the Background
<Border Style="{StaticResource RedCloseButton}" Name="ClearValue" BorderThickness="2" BorderBrush="black" CornerRadius="0,4,4,0" Margin="110,90,0,80"> <Rectangle Margin="10,11,6,10" Fill="White" RadiusX="2" RadiusY="2" IsHitTestVisible="False"></Rectangle></Border>