Back to Devexpress

AppointmentControl.ImageBoxTemplate Property

wpf-devexpress-dot-xpf-dot-scheduling-dot-visual-dot-appointmentcontrol-4ac32654.md

latest3.5 KB
Original Source

AppointmentControl.ImageBoxTemplate Property

Gets or sets a data template visualized in the appointment’s bottom right corner where recurrence and reminder icons are located. This is a dependency property.

Namespace : DevExpress.Xpf.Scheduling.Visual

Assembly : DevExpress.Xpf.Scheduling.v25.2.dll

NuGet Package : DevExpress.Wpf.Scheduling

Declaration

csharp
public DataTemplate ImageBoxTemplate { get; set; }
vb
Public Property ImageBoxTemplate As DataTemplate

Property Value

TypeDescription
DataTemplate

A DataTemplate object that is the data template displayed in the appointment’s image panel.

|

Remarks

Use the ImageBoxTemplate property to display an image or other visual element in the AppointmentImagesPanel after the recurrence and reminder icons.

Example

This code snippet sets the AppointmentControl properties to display the appointment’s start and end time, location and description. It also demonstrates how to display an image in the appointment’s bottom right corner.

View Example

xaml
<DataTemplate x:Key="myImageBox">
    <Image Margin="2" Height="16" Width="16"
           Source="{Binding Appointment.CustomFields[FirstVisit], Converter={local:ConditionToImageSourceConverter}}" />
</DataTemplate>
<Style x:Key="appointmentStyle" TargetType="dxschv:AppointmentControl">
    <Setter Property="ShowInterval" Value="True"/>
    <Setter Property="ShowDescription" Value="True"/>
    <Setter Property="ImageBoxTemplate" Value="{StaticResource myImageBox}"/>
</Style>

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the ImageBoxTemplate property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

wpf-scheduler-customize-appointment-appearance/CS/CustomizeAppointmentExample/MainWindow.xaml#L58

xml
<Setter Property="ShowDescription" Value="True"/>
    <Setter Property="ImageBoxTemplate" Value="{StaticResource myImageBox}"/>
</Style>

See Also

AppointmentControl Class

AppointmentControl Members

DevExpress.Xpf.Scheduling.Visual Namespace