menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DateRangePickerModel<TValue> - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class DateRangePickerModel<TValue>

    Interface for a class DateRangePicker.

    Inheritance
    System.Object
    DateRangePickerModel<TValue>
    Namespace: Syncfusion.Blazor.Calendars
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class DateRangePickerModel<TValue> : Object
    Type Parameters
    Name Description
    TValue

    .

    Constructors

    DateRangePickerModel()

    Declaration
    public DateRangePickerModel()

    Properties

    AllowEdit

    Specifies a boolean value whether the DateRangePicker allows user to change the value via typing. When set as false, the DateRangePicker allows user to change the value via picker only.

    Declaration
    public bool AllowEdit { get; set; }
    Property Value
    Type
    System.Boolean

    Blur

    Triggers when the input loses the focus.

    Declaration
    public EventCallback<object> Blur { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Change

    Triggers when the DateRangePicker value is changed.

    Declaration
    public EventCallback<object> Change { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Cleared

    Triggers when daterangepicker value is cleared using clear button.

    Declaration
    public EventCallback<object> Cleared { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Close

    Triggers when the popup is closed.

    Declaration
    public RangePopupEventArgs Close { get; set; }
    Property Value
    Type
    RangePopupEventArgs

    Created

    Triggers when the DateRangePicker is created.

    Declaration
    public EventCallback<object> Created { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    CssClass

    Specifies the CSS class name that can be appended with the root element of the DateRangePicker. One or more custom CSS classes can be added to a DateRangePicker.

    Declaration
    public string CssClass { get; set; }
    Property Value
    Type
    System.String

    Depth

    Sets the maximum level of view (Month, Year, Decade) in the Calendar.

    Depth view should be smaller than the Start view to restrict its view navigation.

    .
    Declaration
    public CalendarView Depth { get; set; }
    Property Value
    Type
    CalendarView

    Destroyed

    Triggers when the DateRangePicker is destroyed.

    Declaration
    public EventCallback<object> Destroyed { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Enabled

    Specifies a boolean value that indicates whether the DateRangePicker allows the user to interact with it.

    Declaration
    public bool Enabled { get; set; }
    Property Value
    Type
    System.Boolean

    EnablePersistence

    Enable or disable the persisting DateRangePicker's state between the page reloads. If enabled, following list of states will be persisted.

    • StartDate
    • EndDate
    • Value
    .
    Declaration
    public bool EnablePersistence { get; set; }
    Property Value
    Type
    System.Boolean

    EnableRtl

    Enable or disable rendering DateRangePicker in right to left direction.

    Declaration
    public bool EnableRtl { get; set; }
    Property Value
    Type
    System.Boolean

    EndDate

    Gets or sets the end date of the date range selection.

    Declaration
    public DateTime EndDate { get; set; }
    Property Value
    Type
    System.DateTime

    FirstDayOfWeek

    Sets the calendar's first day of the week. By default, the first day of the week will be based on the current culture.

    Declaration
    public double FirstDayOfWeek { get; set; }
    Property Value
    Type
    System.Double

    FloatLabelType

    Specifies the floating label behavior of the DateRangePicker that the placeholder text floats above the DateRangePicker based on the following values.

    Possible values are:

    • NeverNever floats the label in the DateRangePicker when the placeholder is available.
    • AlwaysThe floating label always floats above the DateRangePicker.
    • AutoThe floating label floats above the DateRangePicker after focusing it or when enters the value in it.
    .
    Declaration
    public FloatLabelType FloatLabelType { get; set; }
    Property Value
    Type
    FloatLabelType

    Focus

    Triggers when the input gets focus.

    Declaration
    public EventCallback<object> Focus { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Format

    Specifies the format of the value that to be displayed in DateRangePicker.

    By default, the format is based on the culture.

    You can set the format to "format:'dd/MM/yyyy hh:mm'".

    .
    Declaration
    public string Format { get; set; }
    Property Value
    Type
    System.String

    HtmlAttributes

    You can add the additional input attributes such as disabled, value, and more to the root element.

    If you configured both the property and equivalent input attribute, then the DateRangePicker considers the property value.

    .
    Declaration
    public object HtmlAttributes { get; set; }
    Property Value
    Type
    System.Object

    KeyConfigs

    Customizes the key actions in DateRangePicker. For example, when using German keyboard, the key actions can be customized using these shortcuts.

    Declaration
    public object KeyConfigs { get; set; }
    Property Value
    Type
    System.Object

    Locale

    Specifies the global culture and localization of the DateRangePicker.

    Declaration
    public string Locale { get; set; }
    Property Value
    Type
    System.String

    Max

    Gets or sets the maximum date that can be selected in the calendar-popup.

    Declaration
    public DateTime Max { get; set; }
    Property Value
    Type
    System.DateTime

    MaxDays

    Specifies the maximum span of days that can be allowed in a date range selection.

    Declaration
    public int MaxDays { get; set; }
    Property Value
    Type
    System.Int32

    Min

    Gets or sets the minimum date that can be selected in the calendar-popup.

    Declaration
    public DateTime Min { get; set; }
    Property Value
    Type
    System.DateTime

    MinDays

    Specifies the minimum span of days that can be allowed in date range selection.

    Declaration
    public int MinDays { get; set; }
    Property Value
    Type
    System.Int32

    Navigated

    Triggers when the Calendar is navigated to another view or within the same level of view.

    Declaration
    public EventCallback<object> Navigated { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Open

    Triggers when the popup is opened.

    Declaration
    public RangePopupEventArgs Open { get; set; }
    Property Value
    Type
    RangePopupEventArgs

    Placeholder

    Specifies the text that is shown as a hint or placeholder until the user focuses or enter a value in DateRangePicker. The property is depending on the FloatLabelType property.

    Declaration
    public string Placeholder { get; set; }
    Property Value
    Type
    System.String

    Presets

    Set the predefined ranges which let the user pick required range easily in a DateRangePicker.

    Declaration
    public List<PresetsModel> Presets { get; set; }
    Property Value
    Type
    System.Collections.Generic.List<PresetsModel>

    Readonly

    Specifies a boolean value whether the DateRangePicker allows the user to change the text.

    Declaration
    public bool Readonly { get; set; }
    Property Value
    Type
    System.Boolean

    RenderDayCell

    Gets or sets the RenderDayCell Triggers when each day cell of the Calendar is rendered.

    Declaration
    public EventCallback<object> RenderDayCell { get; set; }
    Property Value
    Type
    Microsoft.AspNetCore.Components.EventCallback<System.Object>

    Select

    Triggers on selecting the start and end date.

    Declaration
    public RangePickerEventArgs<TValue> Select { get; set; }
    Property Value
    Type
    RangePickerEventArgs<TValue>

    Separator

    Sets or gets the string that used between the start and end date string.

    Declaration
    public string Separator { get; set; }
    Property Value
    Type
    System.String

    ShowClearButton

    Specifies whether to show or hide the clear icon in DateRangePicker.

    Declaration
    public bool ShowClearButton { get; set; }
    Property Value
    Type
    System.Boolean

    Start

    Specifies the initial view of the Calendar when it is opened. With the help of this property, initial view can be changed to year or decade view.

    Declaration
    public CalendarView Start { get; set; }
    Property Value
    Type
    CalendarView

    StartDate

    Gets or sets the start date of the date range selection.

    Declaration
    public DateTime StartDate { get; set; }
    Property Value
    Type
    System.DateTime

    StrictMode

    Gets or sets a value indicating whether StrictMode Specifies the DateRangePicker to act as strict. So that, it allows to enter only a valid date value within a specified range or else it will resets to previous value.

    By default, StrictMode is in false. It allows invalid or out-of-range date value with highlighted error class.

    Declaration
    public bool StrictMode { get; set; }
    Property Value
    Type
    System.Boolean

    Value

    Gets or sets the start and end date of the Calendar.

    Declaration
    public object Value { get; set; }
    Property Value
    Type
    System.Object

    WeekNumber

    Determines whether the week number of the Calendar is to be displayed or not. The week number is displayed in every week row.

    Declaration
    public bool WeekNumber { get; set; }
    Property Value
    Type
    System.Boolean

    Width

    Specifies the width of the DateRangePicker component.

    Declaration
    public object Width { get; set; }
    Property Value
    Type
    System.Object

    ZIndex

    specifies the z-index value of the DateRangePicker popup element.

    Declaration
    public int ZIndex { get; set; }
    Property Value
    Type
    System.Int32
    Back to top Generated by DocFX
    OSZAR »
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved
    OSZAR »