The AppointmentItem element has a default value of Top for the VerticalContentAlignment property for the Windows 11 theme. In other themes, this property has a default value of Stretch.
To change it, create a Style with TargetType="AppointmentItem" and base it on the default AppointmentItemBaseStyle Style. On the newly created Style, set the VerticalContentAlignment property to Stretch (it is currently Top in the Windows11 theme). After that, change the default OrientedAppointmentItemStyleSelector so that each Style for its properties is based on the new Style, rather than the default one (AppointmentItemBaseStyle). Finally, set the custom OrientedAppointmentItemStyleSelector to the AppointmentStyleSelector property of RadScheduleView.
The following code snippet shows this suggestion's implementation:
xmlns:scheduleView="http://schemas.telerik.com/2008/xaml/presentation"
<Style x:Key="CustomAppointmentItemStyle" TargetType="scheduleView:AppointmentItem" BasedOn="{StaticResource AppointmentItemBaseStyle}">
<Setter Property="VerticalContentAlignment" Value="Stretch"/>
</Style>
<scheduleView:OrientedAppointmentItemStyleSelector x:Key="CustomAppointmentItemStyleSelector">
<scheduleView:OrientedAppointmentItemStyleSelector.AgendaViewStyle>
<Style TargetType="scheduleView:AppointmentItem" BasedOn="{StaticResource CustomAppointmentItemStyle}">
<Setter Property="Margin" Value="3 0 3 3"/>
</Style>
</scheduleView:OrientedAppointmentItemStyleSelector.AgendaViewStyle>
<scheduleView:OrientedAppointmentItemStyleSelector.MonthViewStyle>
<Style TargetType="scheduleView:AppointmentItem" BasedOn="{StaticResource CustomAppointmentItemStyle}">
<Setter Property="Margin" Value="2 3 1 0"/>
</Style>
</scheduleView:OrientedAppointmentItemStyleSelector.MonthViewStyle>
<scheduleView:OrientedAppointmentItemStyleSelector.HorizontalStyle>
<Style TargetType="scheduleView:AppointmentItem" BasedOn="{StaticResource CustomAppointmentItemStyle}"/>
</scheduleView:OrientedAppointmentItemStyleSelector.HorizontalStyle>
<scheduleView:OrientedAppointmentItemStyleSelector.VerticalStyle>
<Style TargetType="scheduleView:AppointmentItem" BasedOn="{StaticResource CustomAppointmentItemStyle}">
<Setter Property="Margin" Value="1"/>
<Setter Property="ResizeCursor" Value="SizeNS"/>
<Setter Property="Template" Value="{StaticResource AppointmentItemVerticalControlTemplate}"/>
</Style>
</scheduleView:OrientedAppointmentItemStyleSelector.VerticalStyle>
</scheduleView:OrientedAppointmentItemStyleSelector>
<Style TargetType="scheduleView:RadScheduleView" BasedOn="{StaticResource RadScheduleViewStyle}">
<Setter Property="AppointmentStyleSelector" Value="{StaticResource CustomAppointmentItemStyleSelector}"/>
</Style>
In AgendaView, you can see the start, end, and subject of each appointment. When All Day event is set to one appointment, its start and end time is not changed. The text can be changed to All Day Event.
Hello ,
some of our users noticed that the RadScheduleView control has a weird display bug in timeline mode when
The following screenshot shows, what the timeline should look like (I used the default Calendar template and added a few more resources and random appointments for each resource by modifying SampleContentService.cs a bit, see comments in attachment, and adding the resources in CalendarView.xaml, l.316):
And the following Screenshot shows what the same view looks like under the previously mentioned circumstances. It seems that the resource headers are not rendered anymore and all appointments are stuck to the first row.
Steps to reproduce:
Whenever this display bug occurs, any change like scrolling, resizing the window, adding an appointment restores the correct layout.
This problem seems to exist in UI for WPF 2020 R2 and R3
If I can provide you with any more information, please let me know.
Regards,
Simon Müller
Hofmann Fördertechnik GmbH
The group header button in the Agenda view is not localized in some Telerik themes.
To work this around, extract the default GroupHeaderTemplateSelector from the Telerik.Windows.Controls.ScheduleView.xaml file. Then replace the Text binding of the second TextBlock in the AgendaViewHorizontalTopDateTemplate. It should be:
<telerik:GroupHeaderTemplateSelector.AgendaViewHorizontalTopDateTemplate>
<DataTemplate>
<ContentPresenter>
<ContentPresenter.Content>
<StackPanel Orientation="Horizontal" VerticalAlignment="Top" Margin="8 0 10 0">
<TextBlock Margin="0 0 7 0" FontSize="40" Text="{Binding Name, StringFormat='{}{0:dd}'}" />
<StackPanel Orientation="Vertical" Margin="0 10 0 0" VerticalAlignment="Top">
<TextBlock Text="{Binding Name, StringFormat='{}{0:dddd}'}" />
<TextBlock Text="{Binding Name, StringFormat='{}{0:MMMM, yyyy}'}" />
</StackPanel>
</StackPanel>
</ContentPresenter.Content>
</ContentPresenter>
</DataTemplate>
</telerik:GroupHeaderTemplateSelector.AgendaViewHorizontalTopDateTemplate>
When the RecurrenceFrequency is set to Year. The GetOccurrences() method of the RecurrencePattern does not respect the Interval property.