I derived from a TextBox and called it MyTextBox. On my LayoutAwarePage I created 2 SolidColorBrush props: MyBackground and MyBorder. In the Xaml of that page I wrote a ResourceDictionary with style to the control MyTextBox:
<Grid.Resources>
<ResourceDictionary>
<Style TargetType="a:MyTextBox">
<Setter Property="Background" Value="{Binding MyBackground}"></Setter>
<Setter Property="BorderBrush" Value="{Binding MyBorder}"></Setter>
<Setter Property="Width" Value="200"></Setter>
<Setter Property="IsReadOnly" Value="False"></Setter>
<Setter Property="BorderBrush" Value="3"></Setter>
</Style>
</ResourceDictionary>
</Grid.Resources>
When I run this page I can't see the control. I didn't forget to create a DataContext for the page, and the properties are true colors (not black). Any idea how to solve this?