Date Picker – blue border around item in 1st column and 1st row in the calendar when Selected Date set through binding.

Nov 3, 2008 at 3:33 PM
Edited Nov 3, 2008 at 9:01 PM

Thank you for Date Picker control. I wrote my own, but this one is much better. Great job!

The actual selected date has blue background and selected right, but the border getting set only when date picked through the calendar.

 

Any suggestions?                                                                                                                                                              Thanks. Lena
 

 

Coordinator
Nov 3, 2008 at 11:56 PM
Edited Nov 4, 2008 at 6:16 PM
Thanks for finding this issue. I have devised a solution for you that should work. You are going to need to create a local Style for CalendarDayButton that is identical to the one currently in the source. Inside the Style's ControlTemplate's Triggers collection , you can add the following two triggers:

<Trigger Property="IsInactive" Value="True">
        
<Setter TargetName="DayButtonFocusVisual" Property="Visibility" Value="Collapsed" />
</Trigger>
<

 

Trigger Property="IsSelected" Value="True">
        <Setter TargetName="DayButtonFocusVisual" Property="Visibility" Value="Visible" />
</Trigger

-Eric Fabricant, MSFT
Nov 4, 2008 at 2:47 PM
Thank You so much, ericf! It worked!
                                                Lena