Siticone Logo
Siticone UI
DOCS
v2025.12.15
Docs Date Time Picker

Siticone Date Time Picker

The SiticoneDateTimePicker is a premium calendar control that goes far beyond the standard Windows Forms picker. It supports Date Ranges (start and end dates), Multiple Selection, and extensive styling for every element including navigation chevrons, day headers, and today buttons.

Selection Modes

Configure how users interact with the calendar. Whether it's picking a single birthday, a vacation range, or multiple appointment dates.

Property Type Description
SelectionMode SelectionMode
  • Single: Select one date (Default).
  • Range: Select a start and end date. All days in between are highlighted.
  • Multiple: Toggle individual dates on/off independently.
Date DateTime? The currently selected date (Single mode). Returns null if nothing is selected.
RangeStartDate DateTime? The start date of the selection range (Read Only).
RangeEndDate DateTime? The end date of the selection range (Read Only).
SelectedDates List<DateTime> A list of all currently selected dates (useful for Multiple/Range modes).

Formatting & Constraints

Control how the date is displayed in the text box and restrict selectable dates.

Property Type Description
DateFormat DateFormat Predefined formats like ShortDate, LongDate, YearMonth, or Custom.
CustomDateFormat string The format string to use when DateFormat is set to Custom (e.g., "dd MMM yyyy").
MinDate DateTime The earliest date a user can select.
MaxDate DateTime The latest date a user can select.
LockedDates List<DateTime> A list of specific dates that are disabled/unselectable (e.g., holidays).

Calendar Appearance

Deep customization options for the dropdown calendar visuals.

Property Type Description
CalendarBackgroundColor Color Background color of the calendar grid.
NavigationPanelBackColor Color Background color of the top navigation bar (Month/Year selector).
CalendarSelectedDateBackColor Color Background color for the selected date(s).
CalendarRangeDateBackColor Color Background color for dates inside a selected range (between start and end).
HighlightWeekends bool If true, weekends are styled differently using WeekendDayForeColor.
ShowTodayButton bool Shows a button to quickly jump to the current date.

Input Appearance

Styling for the main text box control.

Property Type Description
FillColor Color Background color of the text box.
BorderColor Color Color of the border.
BorderThickness int Thickness of the border in pixels.
CornerRadius... int Individual corner radii (TopLeft, TopRight, etc.) for rounded styling.
UseGradientFill bool Enables a gradient background for the input box.

Events

Events to handle user interaction. Note the specific events for different selection modes.

DateSelected Event (Single Mode)
// Fired when a single date is selected.
picker.SelectedDateChanged += (s, e) => 
{
                Console.WriteLine($"Selected: {e.SelectedDate.ToShortDateString()}");
                Console.WriteLine($"Is Weekend: {e.IsWeekend}");
};
DateRangeChanged Event (Range Mode)
// Fired when a start/end range is defined.
picker.DateRangeChanged += (s, e) => 
{
                Console.WriteLine($"From: {e.StartDate} To: {e.EndDate}");
                Console.WriteLine($"Total Days: {e.DaysCount}");
    
                // Calculate business days (example logic)
                int businessDays = e.WeekdaysCount;
                Console.WriteLine($"Business Days: {businessDays}");
};
MultipleDatesChanged Event
// Fired when dates are toggled in Multiple mode.
picker.MultipleDatesChanged += (s, e) => 
{
                Console.WriteLine($"Selected Count: {e.Count}");
                foreach (var date in e.SelectedDates)
    {
                Console.WriteLine(date.ToString("d"));
    }
};

Designer Support

The control includes a comprehensive Smart Tag menu for rapid configuration.

Category Features
Theme Presets One-click themes: Light, Dark, Corporate Blue, Green, Purple, Red, Orange.
Calendar Display Quickly switch modes: Single Date, Multiple Date, Date Range.
Form Sizing Presets for the dropdown calendar size (Small, Medium, Large).

Usage Examples

Example 1: Booking Range Picker

Configure the control for a hotel booking system, selecting Check-in and Check-out dates.

C# - Range Selection
private void SetupBookingPicker()
{
    datePicker.SelectionMode = SelectionMode.Range;
    datePicker.DateFormat = DateFormat.Custom;
    datePicker.CustomDateFormat = "MMM dd";
    
                // Styling for the range
    datePicker.CalendarRangeStartDateBackColor = Color.SeaGreen;
    datePicker.CalendarRangeEndDateBackColor = Color.SeaGreen;
    datePicker.CalendarRangeDateBackColor = Color.FromArgb(220, 255, 220); // Light green fill
    
    datePicker.PlaceholderText = "Check-in — Check-out";
    
    datePicker.DateRangeChanged += (s, e) => 
    {
        lblNights.Text = $"Total Nights: {e.DaysCount - 1}"; // -1 because days inclusive
    };
}

Example 2: Validated Appointment Picker

Setup a single date picker that blocks weekends and specific holidays.

C# - Validation & Locking
private void SetupAppointmentPicker()
{
                // Only future dates
    datePicker.MinDate = DateTime.Today;
    datePicker.MaxDate = DateTime.Today.AddMonths(3);
    
                // Lock specific holidays
                var holidays = new List<DateTime> 
    { 
                new DateTime(2023, 12, 25),
                new DateTime(2024, 1, 1)
    };
    datePicker.LockedDates = holidays;
    
                // Visuals for locked dates
    datePicker.CalendarLockedDateBackColor = Color.FromArgb(240, 240, 240);
    datePicker.CalendarLockedDateForeColor = Color.Gray;
    
                // Handle selection attempt on invalid days (via logic, visual feedback is automatic)
    datePicker.SelectedDateChanged += (s, e) =>
    {
                if (e.IsWeekend) 
        {
                MessageBox.Show("We are closed on weekends.");
            datePicker.ClearDates();
        }
    };
}

Example 3: Custom Theming

Applying a dark theme programmatically to match the application style.

C# - Dark Theme
private void ApplyDarkTheme()
{
                // Input Box
    datePicker.FillColor = Color.FromArgb(45, 45, 48);
    datePicker.ForeColor = Color.White;
    datePicker.BorderColor = Color.Gray;
    
                // Calendar Dropdown
    datePicker.CalendarBackgroundColor = Color.FromArgb(45, 45, 48);
    datePicker.NavigationPanelBackColor = Color.FromArgb(60, 60, 60);
    
                // Text colors
    datePicker.CalendarDayHeaderForeColor = Color.Silver;
    datePicker.DayButtonForeColor = Color.White;
    datePicker.DayButtonBackColor = Color.FromArgb(50, 50, 50);
    datePicker.DayButtonHoverForeColor = Color.Cyan;
    
                // Selection
    datePicker.CalendarSelectedDateBackColor = Color.DodgerBlue;
    datePicker.CalendarSelectedDateForeColor = Color.White;
}