<Window.Resources> <Style x:Key="ST" TargetType="TextBox"> <Setter Property="Width" Value="40"></Setter> </Style> </Window.Resources>
Try to omit the x:Key attribute of the Style.
x:Key
Style
Grid
StackPanel
Window
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)