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.

Binding custom datatype in SfSchedule - Month view

Thread ID:

Created:

Updated:

Platform:

Replies:

115996 Mar 12,2014 06:38 PM Feb 28,2018 07:30 AM WinRT 17
loading
Tags: SfSchedule
Timothy J Eicher
Asked On March 12, 2014 06:38 PM

Hello,

I am trying to use a collection of a custom data type "AppointmentViewModel" to bind to the item source of the SfSchedule control. For the most part, I've been able to get this working - items are being displayed at the appropriate location for the different ScheduleTypes (Month, Week, etc.). But I've found a problem while doing template data binding in the Month view.

I want to bind to certain properties of my AppointmentViewModel to affect how the appointment is displayed on the calendar, and I've created a custom DataTemplate for the SfSchedule.AppointmentTemplate property. This works, except when ScheduleType is set to Month. When looking at the Month, only one appointment appears to bind correctly. Any others are drawn in the correct position, but their DataTemplate fails to bind.

I investigated further, and found that the reason this is happening is because the DataContext of the DataTemplate is not getting set correctly in the Month view, except for the first AppointmentViewModel. I added an event handler for DataContextChanged in my DataTemplate, and I can see by debugging when this event fires that the DataContext is never set to an instance of AppointmentViewModel, except for the first item. It is being set instead to an instance of "Syncfusion.UI.Xaml.Schedule.ScheduleAppointment".

The  debugging output window also displays a binding error message that also confirms this problem:
Error: BindingExpression path error: 'CustomProperty' property not found on 'Syncfusion.UI.Xaml.Schedule.ScheduleAppointment'. BindingExpression: Path='CustomProperty' DataItem='Syncfusion.UI.Xaml.Schedule.ScheduleAppointment'; target element is 'Windows.UI.Xaml.Controls.TextBlock' (Name='null'); target property is 'Text' (type 'String')

Please advise on how to resolve this. Thanks!

Joy Oyiess Rex  K [Syncfusion]
Replied On March 13, 2014 02:52 AM

Hi Timothy,

 

Thanks for your interest in Syncfusion products.

 

We have already noted the mentioned issue and we have fixed it. The fix for this issue will be included in our upcoming volume release (Vol 1 Mar , 2014), which is estimated to be available by the end of this month.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


Timothy J Eicher
Replied On March 13, 2014 11:24 AM

That's great news, thank you!

I also have a question about custom styling. I'd like to override the default template of the SfSchedule control so I can make the header match the style of my app more closely. I found that setting a template for the HeaderTitleBar was not enough, because I would like to change the location of the left/right arrows which are located in the main template. However, I can't seem to use the template which is included in the generic.xaml file, because it tries to set and use internal properties: 
HeaderTitleBarView.CurrentScheduleType 
HeaderTitleBarView.SelectedDates
which want to be bound to other internal properties:
SfSchedule.PrevSelectedDates
SfSchedule.CurrentSelectedDates

Is there any possibility that these will be changed to public in the March release? Or is there another way to set the main template?

I can move this question to a new thread if that will be helpful.

Thanks!

Kesem Zur-Korakin
Replied On March 13, 2014 02:22 PM

Hi,

I'm encountering the same issue...

Is the new version out already ? How can I install it ?

Thanks,

Kesem


Joy Oyiess Rex  K [Syncfusion]
Replied On March 14, 2014 12:36 AM

Hi Kesem,

 

Thanks for your interest Syncfusion products.

 

As mentioned in our previous update, the fix for this issue will be included in our upcoming volume release (Vol 1 Mar , 2014), which is estimated to be available by the end of this month.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


Joy Oyiess Rex  K [Syncfusion]
Replied On March 14, 2014 06:36 AM

That's great news, thank you!

I also have a question about custom styling. I'd like to override the default template of the SfSchedule control so I can make the header match the style of my app more closely. I found that setting a template for the HeaderTitleBar was not enough, because I would like to change the location of the left/right arrows which are located in the main template. However, I can't seem to use the template which is included in the generic.xaml file, because it tries to set and use internal properties: 
HeaderTitleBarView.CurrentScheduleType 
HeaderTitleBarView.SelectedDates
which want to be bound to other internal properties:
SfSchedule.PrevSelectedDates
SfSchedule.CurrentSelectedDates

Is there any possibility that these will be changed to public in the March release? Or is there another way to set the main template?

I can move this question to a new thread if that will be helpful.

Thanks!

Hi Timothy,

 

Thanks for you previous update.

 

We have analysed your requirement. Based on the implementation of SfSchedule control, we aren’t considered to expose those APIs publicly. Instead your requirement can be achieved by collapsing the default navigation buttons (left and right arrow) from the Schedule and customizing   the default template for  HeaderTitleBarView.

We are currently working on it in the sample level, we will update you the sample in two business days(Mar 18, 2014).

 

Please let us know, if you have any concerns.

 

Regards,

Joy Oyiess Rex K


Joy Oyiess Rex  K [Syncfusion]
Replied On March 18, 2014 12:40 AM

Hi Timothy,

 

We appreciate your patience.

 

We have created a simple sample based on you requirement. Please find the sample in the attachment.

 

In the provided sample, we have collapsed the default navigation buttons (left/right arrows) from the Schedule and customized the default template for  "HeaderTitleBarView" by handled the VisibleDates on the sample. As there is an issue with "Button" while place it in the “HeaderTitleBarView”, we have used a "ContentPresenter" to achieve your requirement of position the navigation button based on our requirement. And  also we have fixed the issue with "Button" in the "HeaderTitleBarView", the fix for this issue will be included in our upcoming volume release, which is estimated to be available by the end of this month.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


Attachment: ScheduleHeaderFormat_WinRT_8cb0c1ad.zip

Timothy J Eicher
Replied On March 19, 2014 01:27 PM




Timothy J Eicher
Replied On March 19, 2014 01:31 PM

Sorry, that last reply was just to test the server, because on my last attempt at a reply the server returned an error and my text was lost.

Thank you for the provided example. It does seem to fix the problem, but it also goes to some strange lengths to get the work-around in place. From where I'm standing, it seems it would be preferable to make the properties used by the default more accessible, rather than having to do code gymnastics to get the control styled.

But nonetheless, thank you!

Timothy J Eicher
Replied On March 19, 2014 01:33 PM

Are you aware of the the bug with the snapped views on the Schedule control? I've noticed that after moving to a different month/week/day and having the app resized, the drawing gets really messed up.

Joy Oyiess Rex  K [Syncfusion]
Replied On March 20, 2014 12:38 AM

Are you aware of the the bug with the snapped views on the Schedule control? I've noticed that after moving to a different month/week/day and having the app resized, the drawing gets really messed up.

Hi Timothy,

 

Thanks for you update.

 

We have already noted the mentioned issue and fixed it, the fix for this issue will also be included in our upcoming volume release (Vol 1 Mar , 2014), which is estimated to be available by the end of this month.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


Sebastien Lachance
Replied On April 15, 2014 02:46 PM

Hello,

Concerning the Snap View, Timothy (my colleague) reported that moving to a different mode view, the drawing gets really messed up.

Now, with the new release, it causes the app to crash. The issue can be easily reproduced with the provided sample.

Is it possible to get hotfix? What is the procedure?

Thank You

Sébastien


Joy Oyiess Rex  K [Syncfusion]
Replied On April 16, 2014 05:20 AM

Hi Sébastien,

 

Thanks for your interest in Syncfusion Products.

 

Your colleague Timothy, didn’t provide us any sample regarding this issue, but we have already noted the issue and the fix for this issue was already  included in our Essential Studio Volume 1, 2014 release. If the mentioned  issue still exist in the current version (v12.1.0.43), then kindly provide us a sample along with more information to reproduce the issue. So that we can analyse on it and provide you better solution.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


Sébastien Lachance
Replied On April 16, 2014 09:20 AM

Hi,

I don't understand your previous answer. Last month, we mentioned the issue that the Schedule control was not correctly drawn in the application is not on full screen (snap view) and you replied that the fix will be corrected in the 2014 volume 1.

And now you saying that you don't understand the issue. I'm confusing.

With the 2014 volume 1 version, the Schedule control will crash the application when the app is not on full screen. You can reproduce the issue with the provided sample from Syncfusion. Open the sample, compile, execute the Schedule sample and resize the application and then you switch from mode view.

I provided a zip file that contains a screenshot to show you what is an application not on full screen.

Thank you

Sébastien


Attachment: Untitled_168ea173.zip

Joy Oyiess Rex  K [Syncfusion]
Replied On April 17, 2014 08:58 AM

Hi Sébastien,

 

As in our previous version we have some, View alignment issue after resizing and  switching between views. So we have logged an issue report regarding that and fixed it. Those issue fix was already included in our 2014 Volume 1, regarding issue with "App crashed after switching the views  while snapping the schedule",  we are currently analysing on this in the sample level. we will let you know the details in two business days (Apr 22, 2014).

 

Please let us know, if you have any concerns.

 

Regards,

Joy Oyiess Rex K



Joy Oyiess Rex  K [Syncfusion]
Replied On April 22, 2014 07:59 AM

Hi Sébastien,

 

We appreciate your patience.

 

We have analysed on the reported issue and we are able to reproduce the mentioned issue in Week and WorkWeek Views of the Schedule, we have logged an issue report regarding this in our database. The fix for this issue will be included in our upcoming WinRT SP release.

 

Please let us know, if you have any concerns.

 

Regards,

Joy Oyiess Rex K


????
Replied On February 26, 2018 11:49 PM

Hi Timothy,

 

Thanks for your interest in Syncfusion products.

 

We have already noted the mentioned issue and we have fixed it. The fix for this issue will be included in our upcoming volume release (Vol 1 Mar , 2014), which is estimated to be available by the end of this month.

 

Please let us know, if you need any further assistance.

 

Regards,

Joy Oyiess Rex K


I am agree with the privacy policy and terms of service. What next?

Padmini Ramamurthy [Syncfusion]
Replied On February 28, 2018 07:30 AM

Hi, 
  
Thanks for contacting Syncfusion Support, 
  
Can you please provide more details on your technical requirement? so that, we could proceed further and assist you accordingly. 
  
Regards, 
Padmini R. 


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.

;