$99 VS $1000+. UI Control for ASP.NET AJAX(contains chart and gridview).
Calendar Controls for WinForms UI Tutorial
Customize appearance with template in C# for .NET Windows Forms projects
Home > WinForms UI Controls > User Manual > Customize Appearance Template in C#

Templates for Customizing Appearance - WinForms Calendar

The Calendar Control for Windows Forms applications provides a collection of dynamic templates. There are several dynamic templates available for design rich presentation for the calendar days in Windows Forms applications. The feature even allows developers customizing a single day. This functionality will be powerful when developers need to implement an interface with scheduler appearance, which could add additional information and images about events, links to various resources. The dynamic templates can be used by other Windows Forms UI Component.
The dynamic templates support the Special Days collection of Calendar Day objects. Calendar Day contains a property, TemplateItem, which is HostItem type, and accepts a Control in the constructor.
  1. The following is an example that shows the process of using templates
  2. Create a Picture Box control and assigning an image from an Image List.
  3. Then create a new instance of HostItem and pass the picture box in its constructor.
  4. Finally set the TemplateItem property of the special day.
  5. When the day is rendered, the associated image will be displayed in the cell for that day.
  6. In the example, an instance of Image List on the form should be populated with at least one image and one special day at least should be added to the SpecialDays collection of Calendar.

PictureBox pictureBox = new PictureBox();
pictureBox.SizeMode = PictureBoxSizeMode.StretchImage;
pictureBox.Image = imageList1.Images[0];
HostItem hostItem = new HostItem(pictureBox);
Calendar1.SpecialDays[0].TemplateItem = hostItem;
UI Controlsfor Windows Forms
.NET WinForms UI Overview.NET WinForms UI Features.NET WinForms UI GuideC# WinForms UI DesignVB.NET WinForms UI Design
WinForms UI Controls