Appointment Item Height in Timeline View

5 posts, 1 answers
  1. JiFong Chen
    JiFong Chen avatar
    13 posts
    Member since:
    Aug 2007

    Posted 27 Jun 2011 Link to this post

    Is there a way to change the appointment item height in timeline view?

    I tried with:

    <Style x:Key="CategoryStyle" TargetType="telerik:AppointmentItem">
      <Setter Property="Height" Value="100" />
    </Style>

    and when I compile+run, the height doesn't change.

    Please advise.

  2. Answer
    Hristo
    Admin
    Hristo avatar
    832 posts

    Posted 27 Jun 2011 Link to this post

    Hello JiFong,

    In TimelineView definition you could set StretchGroupHeaders property to True so that group headers take all availabe space and then if you want AppointmentItems to stretch also you have to set StretchAppointments property to True.
    If you do not want to stretch group headers and appointment items but just to increase the height of AppointmentItems then all you have to do is to set MinAppointmentHeight of RadScheduleView.

    Let us know if you need more information/

    All the best,
    Hristo
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
  4. JiFong Chen
    JiFong Chen avatar
    13 posts
    Member since:
    Aug 2007

    Posted 27 Jun 2011 Link to this post

    Thank you very much!
  5. Rebecca
    Rebecca avatar
    28 posts
    Member since:
    Nov 2010

    Posted 10 Oct 2012 Link to this post

    Hi (Hristo),

    I tried setting the TimelineViewDefinition's StretchAppointments property to True as you suggested and it did not stretch the appointment.

    This is what I have in code:
    <telerik:RadScheduleView.ViewDefinitions>
      <telerik:TimelineViewDefinition VisibleDays="1" 
         MinTimeRulerExtent="55"
         MaxTimeRulerExtent="{Binding ActualWidth, ElementName=ParentElement}"
         MajorTickLength="1h"
         MinorTickLength="15min"
         StretchGroupHeaders ="True"
         StretchAppointments="True"
         GroupHeaderDateStringFormat="{StaticResource CustomDateStringFormat}"
         TimerulerMajorTickStringFormat="{StaticResource CustomTimeStringFormat}" />
    </telerik:RadScheduleView.ViewDefinitions>



    The only way that I have been able to increase the size of the appointment is to specify a value for the MinAppointmentHeight property of the RadScheduleView.

    However, this is not what I would prefer using because I would like it to stretch.

    I am looking forward to hearing your suggestions on how to achieve this.

    -Rebecca


  6. Vladi
    Admin
    Vladi avatar
    744 posts

    Posted 15 Oct 2012 Link to this post

    Hi Rebecca,

    The StretchGroupHeaders and StretchAppointments properties are designed to be used when there are Resources in the ScheduleView and if there isn't any resources in the control they will not change the behavior of the appointments in Timeline view.

    If you add Resources in your project and then set the StretchGroupHeaders/StretchAppointments properties the appointments in those resources will stretch.

    If you want to change the height of the appointments in Timeline view you need to set the MinAppointmentHeight property.

    Greetings,
    Vladi
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top
UI for WPF is Visual Studio 2017 Ready