Custom Appointment Class and Different Binding Field

5 posts, 0 answers
  1. Yves
    Yves avatar
    1 posts
    Member since:
    Jan 2012

    Posted 05 Jan 2012 Link to this post

    Dear all,

    I would like to use a class that implements the IAppointment interface because I would like to store additional information, other than just StartDate, EndDate, etc.

    The problem I have is that I haven't found yet a way to bind the RadCalendar to other field than Subject (using {Binding DetailText}) or getting the day number (when I try {Binding Text}).
    For example, in my class I have a field named "MeetingRoom", and would like to use it in my template.

    Do you have a sample on how to achieve this ?

    Thanks a lot for your help
    Best Regards
    Yves
  2. Valentin.Stoychev
    Admin
    Valentin.Stoychev avatar
    2198 posts

    Posted 06 Jan 2012 Link to this post

    Hi,

    This is the expected behavior. The DataContext of each calendar item is an object instance of the CalendarButtonContentInfo class. To bind to your apointments you need to use the Appointments property with a Binding converter to get the values you want.

    Please let us know if you need more help on this.

    Kind regards, Valentin.Stoychev
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
  4. Einar
    Einar avatar
    2 posts
    Member since:
    Sep 2013

    Posted 12 Nov 2013 Link to this post

    Can you show me a demo of how this is achieved, it would be well appreciated.

    Regards,
    A man that's bad at XAML
  5. Todor
    Admin
    Todor avatar
    778 posts

    Posted 15 Nov 2013 Link to this post

    Hi Einar,

    Thank you for writing.

    I have attached an example illustrating how you can display custom information from the appointments by using a converter.

    I hope this information helps.
     
    Regards,
    Todor
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINDOWS PHONE 7.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  6. Einar
    Einar avatar
    2 posts
    Member since:
    Sep 2013

    Posted 22 Nov 2013 Link to this post

    Thank you, that was exactly what I needed
Back to Top
DevCraft banner