<local:cdsSpinner x:Name="txtHoleCount1" Text="{Binding Path=HolePattern1.HoleCount, ElementName=winBoltCircle}" PreviewGotKeyboardFocus="TextBox_PreviewGotKeyboardFocus" Height="25" Width="75" Style="{StaticResource cdsSpinnerStyle}"/>But, I'm getting some "value cannot be null" error related to the I colors in these lines: I don't understand the error because I see those colors listed in the resource code you gave me.
<ControlTemplate.Triggers> <Trigger Property="IsEnabled" Value="False"> <Setter TargetName="Border" Property="Background" Value="{StaticResource DisabledBackgroundBrush}"/> <Setter TargetName="Border" Property="BorderBrush" Value="{StaticResource DisabledBackgroundBrush}"/> <Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/> </Trigger> </ControlTemplate.Triggers>(I have not added the event handler yet, but I just wanted to see it render at run-time for now). Also, you may get an error from my ObjectDataProvider resource, but it runs fine. It's a way to display the enum of the Hole.HoleType in the UI. It uses a complex syntax to drill into an enum in a class in a class that I think the designer cannot render, but it does run. It's really cool. I found the example on the web at some Josh Smith on WPF blog).