menu

ASP.NET Web Forms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DateTimePickerPropertiesBuilder

    Show / Hide Table of Contents

    Class DateTimePickerPropertiesBuilder

    Inheritance
    System.Object
    DateTimePickerPropertiesBuilder
    Implements
    IPropertiesBuilder
    System.Web.IHtmlString
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Syncfusion.JavaScript
    Assembly: Syncfusion.EJ.dll
    Syntax
    public class DateTimePickerPropertiesBuilder : IPropertiesBuilder, IHtmlString

    Constructors

    DateTimePickerPropertiesBuilder()

    Initializes a new instance of the DateTimePickerPropertiesBuilder class.

    Declaration
    public DateTimePickerPropertiesBuilder()

    DateTimePickerPropertiesBuilder(DateTimePicker)

    Initializes a new instance of the DateTimePickerPropertiesBuilder class by the specified DateTimePicker object.

    Declaration
    public DateTimePickerPropertiesBuilder(DateTimePicker dateTimePicker)
    Parameters
    Type Name Description
    DateTimePicker dateTimePicker

    Fields

    dateTimePicker

    Specifies the instance of the DateTimePicker class.

    Declaration
    public DateTimePicker dateTimePicker
    Field Value
    Type Description
    DateTimePicker

    Methods

    AllowEdit()

    Specifies to edit the date values in the input field of the date time picker.

    Declaration
    public DateTimePickerPropertiesBuilder AllowEdit()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    AllowEdit(Boolean)

    Specifies to edit the date values in the input field of the date time picker based on the boolean argument specified.

    Declaration
    public DateTimePickerPropertiesBuilder AllowEdit(bool allowEdit)
    Parameters
    Type Name Description
    System.Boolean allowEdit
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ClientSideEvents(Action<DateTimePickerClientSideEventsBuilder>)

    Specifies to trigger the DateTimePicker client side events.

    Declaration
    public DateTimePickerPropertiesBuilder ClientSideEvents(Action<DateTimePickerClientSideEventsBuilder> clientSideEvents)
    Parameters
    Type Name Description
    System.Action<DateTimePickerClientSideEventsBuilder> clientSideEvents
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    CssClass(String)

    Specifies the root CSS class to DateTimePicker for theme customization.

    Declaration
    public DateTimePickerPropertiesBuilder CssClass(string customCssClass)
    Parameters
    Type Name Description
    System.String customCssClass
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    DateTimeFormat(String)

    Specifies the date and time format displayed in the DateTimePicker.

    Declaration
    public DateTimePickerPropertiesBuilder DateTimeFormat(string dateTimeFormat)
    Parameters
    Type Name Description
    System.String dateTimeFormat
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    DateTimePickerButtonText(Action<ButtonTextBuilder>)

    Specifies the custom text for the buttons inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder DateTimePickerButtonText(Action<ButtonTextBuilder> buttonText)
    Parameters
    Type Name Description
    System.Action<ButtonTextBuilder> buttonText
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    DateTimePickerDrillDown(Action<TimeDrillDownBuilder>)

    Specifies drilldown to multiple levels of view (hours/minutes/seconds) in DateTimepicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder DateTimePickerDrillDown(Action<TimeDrillDownBuilder> timeDrillDown)
    Parameters
    Type Name Description
    System.Action<TimeDrillDownBuilder> timeDrillDown
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    DayHeaderFormat(Header)

    Specifies the header format of the date picker inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder DayHeaderFormat(Header dayHeaderFormat)
    Parameters
    Type Name Description
    Header dayHeaderFormat
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    DepthLevel(Period)

    Specifies the drill down level in date picker inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder DepthLevel(Period depthLevel)
    Parameters
    Type Name Description
    Period depthLevel
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Enabled()

    Specifies the DateTimePicker control respond for user interaction.

    Declaration
    public DateTimePickerPropertiesBuilder Enabled()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Enabled(Boolean)

    Allows the DateTimePicker control respond for user interaction with the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder Enabled(bool enabled)
    Parameters
    Type Name Description
    System.Boolean enabled
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    EnablePersistence()

    Specifies to persists the DateTimePicker model value upon form post or browser refresh.

    Declaration
    public DateTimePickerPropertiesBuilder EnablePersistence()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    EnablePersistence(Boolean)

    Specifies to persists the DateTimePicker model value upon form post or browser refresh with the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder EnablePersistence(bool enablePersistence)
    Parameters
    Type Name Description
    System.Boolean enablePersistence
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    EnableRTL()

    Specifies the DateTimePicker input field and popup with rounded corners by the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder EnableRTL()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    EnableRTL(Boolean)

    Specifies to align the input field and popup in right to left direction.

    Declaration
    public DateTimePickerPropertiesBuilder EnableRTL(bool enableRTL)
    Parameters
    Type Name Description
    System.Boolean enableRTL
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    EnableStrictMode(Boolean)

    Specifies to allow the invalid date in the DateTimePicker input field.

    Declaration
    public DateTimePickerPropertiesBuilder EnableStrictMode(bool enableStrictMode)
    Parameters
    Type Name Description
    System.Boolean enableStrictMode
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    HeaderFormat(String)

    Specifies the header format to be displayed in the date picker calendar inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder HeaderFormat(string headerFormat)
    Parameters
    Type Name Description
    System.String headerFormat
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Height(String)

    Sets the height of the DateTimePicker input field.

    Declaration
    public DateTimePickerPropertiesBuilder Height(string height)
    Parameters
    Type Name Description
    System.String height
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    HtmlAttributes(IDictionary<String, Object>)

    Specifies to map the field of HTML attributes for the DateTimePicker element.

    Declaration
    public DateTimePickerPropertiesBuilder HtmlAttributes(IDictionary<string, object> itemHtmlAttributes)
    Parameters
    Type Name Description
    System.Collections.Generic.IDictionary<System.String, System.Object> itemHtmlAttributes
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Interval(Int32)

    Specifies the time interval between the two adjacent time values in the time popup.

    Declaration
    public DateTimePickerPropertiesBuilder Interval(int interval)
    Parameters
    Type Name Description
    System.Int32 interval
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Locale(String)

    Specifies to display the DateTimePicker in the specified culture.

    Declaration
    public DateTimePickerPropertiesBuilder Locale(string locale)
    Parameters
    Type Name Description
    System.String locale
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    MaxDateTime(DateTime)

    Specifies the maximum date and time value of the DateTimePicker with the DateTime argument.

    Declaration
    public DateTimePickerPropertiesBuilder MaxDateTime(DateTime maxDateTime)
    Parameters
    Type Name Description
    System.DateTime maxDateTime
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    MaxDateTime(String)

    Specifies the maximum date and time value of the DateTimePicker with the string argument.

    Declaration
    public DateTimePickerPropertiesBuilder MaxDateTime(string maxDateTime)
    Parameters
    Type Name Description
    System.String maxDateTime
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    MinDateTime(DateTime)

    Declaration
    public DateTimePickerPropertiesBuilder MinDateTime(DateTime minDateTime)
    Parameters
    Type Name Description
    System.DateTime minDateTime
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    MinDateTime(String)

    Specifies the minimum date and time value of the DateTimePicker with the string argument.

    Declaration
    public DateTimePickerPropertiesBuilder MinDateTime(string minDateTime)
    Parameters
    Type Name Description
    System.String minDateTime
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Name(String)

    Specifies the name of the DateTimePicker.

    Declaration
    public DateTimePickerPropertiesBuilder Name(string name)
    Parameters
    Type Name Description
    System.String name
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ReadOnly()

    Specifies to prevent the editing/selecting the date/time in DateTimePicker.

    Declaration
    public DateTimePickerPropertiesBuilder ReadOnly()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ReadOnly(Boolean)

    Specifies to prevent the editing/selecting the date/time in DateTimePicker with the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder ReadOnly(bool readOnly)
    Parameters
    Type Name Description
    System.Boolean readOnly
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Render()

    Renders the DateTimePicker instance.

    Declaration
    public void Render()

    ShowOtherMonths()

    Specifies to show the days of adjacent months in current month calendar of DateTimePicker.

    Declaration
    public DateTimePickerPropertiesBuilder ShowOtherMonths()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ShowOtherMonths(Boolean)

    Specifies to show the days of adjacent months in current month calendar of DateTimePicker by the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder ShowOtherMonths(bool showOtherMonths)
    Parameters
    Type Name Description
    System.Boolean showOtherMonths
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ShowPopupButton()

    Shows the DateTime icon button in the input field.

    Declaration
    public DateTimePickerPropertiesBuilder ShowPopupButton()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ShowPopupButton(Boolean)

    Shows the DateTime icon button in the input field with the specified boolean argument.

    Declaration
    public DateTimePickerPropertiesBuilder ShowPopupButton(bool showPopupButton)
    Parameters
    Type Name Description
    System.Boolean showPopupButton
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ShowRoundedCorner()

    Changes the sharped edges into rounded corner for the DateTimePicker textbox and popup.

    Declaration
    public DateTimePickerPropertiesBuilder ShowRoundedCorner()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ShowRoundedCorner(Boolean)

    Specifies the DateTimePicker input field and popup with rounded corners.

    Declaration
    public DateTimePickerPropertiesBuilder ShowRoundedCorner(bool showRoundedCorner)
    Parameters
    Type Name Description
    System.Boolean showRoundedCorner
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    StartDay(Int32)

    Specifies the calendar's start day of the week in the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder StartDay(int startDay)
    Parameters
    Type Name Description
    System.Int32 startDay
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    StartLevel(Period)

    Specifies the start level view in date picker inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder StartLevel(Period startLevel)
    Parameters
    Type Name Description
    Period startLevel
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    StepMonths(Int32)

    Specifies the number of months to navigate at one click of next and previous button in date picker inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder StepMonths(int stepMonths)
    Parameters
    Type Name Description
    System.Int32 stepMonths
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    TimeDisplayFormat(String)

    Specifies the time format displayed in the time dropdown inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder TimeDisplayFormat(string timeDisplayFormat)
    Parameters
    Type Name Description
    System.String timeDisplayFormat
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    TimePopupWidth(Int32)

    Specifies the width of the time dropdown inside the DateTimePicker popup.

    Declaration
    public DateTimePickerPropertiesBuilder TimePopupWidth(int timePopupWidth)
    Parameters
    Type Name Description
    System.Int32 timePopupWidth
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    TimeZone()

    Allows to set the value of the DateTimePicker based on the timezone.

    Declaration
    public DateTimePickerPropertiesBuilder TimeZone()
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    TimeZone(Boolean)

    Allows to set the value in dateTimepicker based on the timezone.

    Declaration
    public DateTimePickerPropertiesBuilder TimeZone(bool timeZone)
    Parameters
    Type Name Description
    System.Boolean timeZone
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ToHtmlString()

    Represents an HTML-encoded string.

    Declaration
    public string ToHtmlString()
    Returns
    Type Description
    System.String

    ValidationMessage(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder>)

    Sets the jQuery validation error message in DateTimePicker input. This API is deprecated, please use ValidationMessages instead of this.

    Declaration
    [Obsolete("The ValidationMessage property has been deprecated.Use 'ValidationMessages' instead")]
    public DateTimePickerPropertiesBuilder ValidationMessage(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder> validationMessages)
    Parameters
    Type Name Description
    System.Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder> validationMessages
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ValidationMessage(Dictionary<String, Object>)

    Sets the jQuery validation error message in DateTimePicker input. This API is deprecated, please use ValidationMessages instead of this.

    Declaration
    [Obsolete("The ValidationMessage property has been deprecated.Use 'ValidationMessages' instead")]
    public DateTimePickerPropertiesBuilder ValidationMessage(Dictionary<string, object> validationMessage)
    Parameters
    Type Name Description
    System.Collections.Generic.Dictionary<System.String, System.Object> validationMessage
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ValidationMessages(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder>)

    Declaration
    public DateTimePickerPropertiesBuilder ValidationMessages(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder> validationMessages)
    Parameters
    Type Name Description
    System.Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationMessageBuilder> validationMessages
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ValidationMessages(Dictionary<String, Object>)

    Sets the jQuery validation error message in DateTimePicker input.

    Declaration
    public DateTimePickerPropertiesBuilder ValidationMessages(Dictionary<string, object> validationMessage)
    Parameters
    Type Name Description
    System.Collections.Generic.Dictionary<System.String, System.Object> validationMessage
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ValidationRules(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationRuleBuilder>)

    Sets the jQuery validation rules in DateTimePicker input.

    Declaration
    public DateTimePickerPropertiesBuilder ValidationRules(Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationRuleBuilder> validationRule)
    Parameters
    Type Name Description
    System.Action<DateTimePickerPropertiesBuilder.DateTimePickerValidationRuleBuilder> validationRule
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    ValidationRules(Dictionary<String, Object>)

    Sets the jQuery validation rules in DateTimePicker input.

    Declaration
    public DateTimePickerPropertiesBuilder ValidationRules(Dictionary<string, object> validationRule)
    Parameters
    Type Name Description
    System.Collections.Generic.Dictionary<System.String, System.Object> validationRule
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Value(DateTime)

    Specifies the DateTime value of the DateTimePicker with the specified DateTime argument.

    Declaration
    public DateTimePickerPropertiesBuilder Value(DateTime value)
    Parameters
    Type Name Description
    System.DateTime value
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Value(String)

    Specifies the DateTime value of the DateTimePicker with the specified string argument.

    Declaration
    public DateTimePickerPropertiesBuilder Value(string value)
    Parameters
    Type Name Description
    System.String value
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    WatermarkText(String)

    Specifies the place holder value for DateTimePicker input field.

    Declaration
    public DateTimePickerPropertiesBuilder WatermarkText(string watermarkText)
    Parameters
    Type Name Description
    System.String watermarkText
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Width(String)

    Specifies the width of the DateTimePicker input field.

    Declaration
    public DateTimePickerPropertiesBuilder Width(string width)
    Parameters
    Type Name Description
    System.String width
    Returns
    Type Description
    DateTimePickerPropertiesBuilder

    Implements

    IPropertiesBuilder
    System.Web.IHtmlString
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved