Table of Contents
  • Getting Started
  • EO.Pdf
  • EO.Web
    • Overview
    • Installation & Deployement
    • EO.Web ToolTip
    • EO.Web Rating
    • EO.Web Slider & RangeSlider
    • EO.Web ListBox
    • EO.Web ComboBox
    • EO.Web Captcha
    • EO.Web ASPX To PDF
    • EO.Web Slide
    • EO.Web Flyout
    • EO.Web EditableLabel
    • EO.Web ImageZoom
    • EO.Web Floater
    • EO.Web Downloader
    • EO.Web ColorPicker
    • EO.Web HTML Editor
    • EO.Web File Explorer
    • EO.Web SpellChecker
    • EO.Web Grid
    • EO.Web MaskedEdit
    • EO.Web Splitter
    • EO.Web Menu
    • EO.Web Slide Menu
    • EO.Web TabStrip
    • EO.Web TreeView
    • EO.Web Calendar
    • EO.Web Callback
    • EO.Web MultiPage
    • EO.Web Dialog
    • EO.Web AJAXUploader
    • EO.Web ProgressBar - Free!
    • EO.Web ToolBar - Free!
  • EO.WebBrowser
  • EO.Wpf
  • Common Topics
  • Reference
Using Validators with Calendar

Apply to

Calendar, PopupCalendar and DatePicker

Overview

EO.Web Calendar, PopupCalendar and DatePicker work with standard ASP.NET RequiredValidator, RangeValidator and CompareValidator.

When working with these validators, the "value" of the EO.Web Calendar, PopupCalendar and DatePicker is first formatted in the form of "yyyy-MM-dd" or "yyyy-MM-dd hh:mm:ss" before comparison, the former is for value without time components, the later is for value with time components. For example:

  • If the DatePicker is only used to enter a date value, in order to limit a DatePicker's date within 01-MAR-2007 and 10-MAR-2007, you can use a RangeValidator with its MinimumValue set to "2007-03-01" and MaximumValue set to "2007-03-10";
  • If the DatePicker is used to enter both a date and a time value, in order to limit the value within 01-MAR-2007 01:00:00 and 10-MAR-2007 02:00:00, you can use a RangeValidator with its MinimumValue set to "2007-03-01 01:00:00" and MaximumValue set to "2007-03-10 02:00:00";
  • If the DatePicker is only used to enter a time value, in order to limit the value within 01:00:00 and 02:00:00, you can use a RangeValidator with its MinimumValue set to "0001-01-01 01:00:00" and MaximumValue set to "0001-01-01 02:00:00". Note a year value of "0001-01-01" must be included because DatePicker always includes the date when comparing against a RangeValidator.