We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Selected Date not being highlighted

Thread ID:

Created:

Updated:

Platform:

Replies:

121138 Nov 13,2015 05:57 AM Nov 18,2015 11:02 PM WinRT 7
loading
Tags: SfCalendar
Ibrahim Islam
Asked On November 13, 2015 05:57 AM

I have following code for showing the control:

<syncfusion:SfCalendar x:Name="DueDate"
                       HorizontalAlignment="Left"
                       Background="#383842"
                       Width="250"
                       Height="250"
                       SelectionMode="Single"
                       ShowNavigationButton="True"
                       FirstDayofWeek="Monday"
                       PreviousScrollButtonTemplate="{ThemeResource PreviousButtonTemplate}"
                       NextScrollButtonTemplate="{ThemeResource NextButtonTemplate}"
                       HeaderTemplate="{ThemeResource HeaderTemplate}"
                       CellTemplate="{ThemeResource Template}"
                       BorderBrush="#383842"
                       BorderThickness="5"
                       SelectedDateBackground="Red"
                       SelectedDate="{Binding RegistrationDate, Mode=TwoWay}"
                       DisplayDate="{Binding RegistrationDate, Mode=TwoWay}">
</syncfusion:SfCalendar>

As can be seen that I am binding RegistrationDate to both SelectedDate and DisplayDate properties of the control.

RegistrationDate == DateTime.Now;

But when I am setting my RegistrationDate property from my code-behind it is not being highlighted on SfCalendar control.
How can I resolve this?

Mariappan S [Syncfusion]
Replied On November 16, 2015 03:05 AM

Hi Ibrahim,

Thank you for contacting Syncfusion support.

We have prepared sample by using your code snippets and we have checked the reported issue in this sample. But we are unable to reproduce the reported issue in this sample.

Please download the sample from the below link.

Sample link: SfCalendarSample


Please have a look at the sample and if the issue still exists, could you please try reproducing it in the above sample or send reproducible sample and the reproducing steps so that we could sort out the cause of the issue and provide you the solution?

Regards,
Mariappan S.

Ibrahim Islam
Replied On November 16, 2015 09:09 AM

Hi Ibrahim,

Thank you for contacting Syncfusion support.

We have prepared sample by using your code snippets and we have checked the reported issue in this sample. But we are unable to reproduce the reported issue in this sample.

Please download the sample from the below link.

Sample link: SfCalendarSample


Please have a look at the sample and if the issue still exists, could you please try reproducing it in the above sample or send reproducible sample and the reproducing steps so that we could sort out the cause of the issue and provide you the solution?

Regards,
Mariappan S.

Thanks for your reply.
I found out that its because I changed the CellTemplate to one of my custom template.
I have made the change in your solution and attached it back here.
Please see it and suggest what I can do.
Thanks.

Attachment: SfCalendarSample_4ff37a44.zip

Mariappan S [Syncfusion]
Replied On November 17, 2015 05:39 AM

Hi Ibrahim,

We have checked your last updated sample and we are able to reproduce the reported issue. In this sample, you have defined the custom “Background” color of the Grid panel in CellTemplate and this color overrides the SelectedBackgroundColor. So, the highlighted color gets hidden under the CellTemplate.  We have modified the sample and we have removed that “Background” color in that sample.

Please download the modified sample from the below link.

Sample link: SfCalendarSample

Regards,
Mariappan S.


Ibrahim Islam
Replied On November 17, 2015 06:31 AM

Hi Ibrahim,

We have checked your last updated sample and we are able to reproduce the reported issue. In this sample, you have defined the custom “Background” color of the Grid panel in CellTemplate and this color overrides the SelectedBackgroundColor. So, the highlighted color gets hidden under the CellTemplate.  We have modified the sample and we have removed that “Background” color in that sample.

Please download the modified sample from the below link.

Sample link: SfCalendarSample

Regards,
Mariappan S.


Thanks for your reply.
But If I do not set the Background property to my custom color then I cannot get the look I want for the control.
Is there a way that I can set the Background property and also have the SelectedDateBackground property applied too?

Mariappan S [Syncfusion]
Replied On November 18, 2015 01:16 AM

Hi Ibrahim,

We were able to reproduce the “CalendarView Background doesn’t apply while set Background color to CalendarView” issue and have logged defect report regarding this. The fix for this issue will be included in our Service pack2 volume 3 2015 release which is scheduled by end of November 2015.

Regards,
Mariappan S.

Ibrahim Islam
Replied On November 18, 2015 02:07 AM

Hi Ibrahim,

We were able to reproduce the “CalendarView Background doesn’t apply while set Background color to CalendarView” issue and have logged defect report regarding this. The fix for this issue will be included in our Service pack2 volume 3 2015 release which is scheduled by end of November 2015.

Regards,
Mariappan S.

Thanks a lot.
Looking forward to the fix.

Mariappan S [Syncfusion]
Replied On November 18, 2015 11:02 PM

Hi Ibrahim,

Thank you for your update.

We will include the fix for this issue in our Vol 3 2015 Service Pack2 which is scheduled by end of November 2015.

Please let us know if you need further assistance.

Regards,
Mariappan S.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;