# XamlDateRangePicker
**Repository Path**: arlo/XamlDateRangePicker
## Basic Information
- **Project Name**: XamlDateRangePicker
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: main
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2026-03-04
- **Last Updated**: 2026-03-04
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# XamlDateRangePicker
A simple WPF DateRangePicker, that allows to select a date range from a calendar control.

## Motivation
I needed a way to let a user select a date range for a DataGrid filter. After some research I was not able to find a control that was capable of what I wanted, so I created this WPF User Control to have a combination of the WPF DatePicker and the WPF Calendar controls, that allows either selecting a single date or a date range.
## Technologies used
- C#
- .NET 6
- WPF (XAML)
## How to use
Please find a small sample application under [Example](/Example).
The DateRangePicker User Control can be used as follows.
1. Add the project or the user control to your solution/project.
2. Add the namespace for the user control to your XAML
```xaml
xmlns:userControls="clr-namespace:UserControls;assembly=DateRangePicker"
```
3. Use the control in your XAML
```xaml
```
You can bind the SelectedDateRange Property to your ViewModel. This property holds a `ObservableCollection` of either one or two dates. Either the single selected DateTime or the first and the last date of the selected date range.