Two DevExpress ASP.NET Date Edit controls (ASPxDateEdit) can be combined to introduce date range selection capabilities in your web application. One editor is used to specify the start date, another to specify the end date. To link editors, set the StartDateEditID property of the end-date editor to the ID value of the start-date editor.
You can customize date range settings using the DateRangeSettings property, which provides access to the following properties:
- MinDayCount - specifies the minimum number of days in a range.
- MaxDayCount - specifies the maximum number of days in a range.
Note: Date range settings should be specified for the end-date editor.
In this demo, the client-side GetRangeDayCount method is used in the DateChanged event handler to calculate the number of days in a specified range. If the number of days in the specified range exceeds specified range limits, an error message is displayed when the Submit button is clicked.