summaryrefslogtreecommitdiff
path: root/reference/csharp/snippets/Efl.Ui.Datepicker.cs
blob: 4288131ca1ce2e7e9adf2404553a42f5570a7d2c (plain)
1
2
3
4
5
6
7
8
9
10
11
Efl.Ui.Datepicker datepicker = new Efl.Ui.Datepicker(parent);

datepicker.SetDateMin(2000, 1, 1);
datepicker.SetDateMax(2030, 1, 1);
datepicker.SetDate(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day);

datepicker.DateChangedEvent += (sender, args) =>
{
    datepicker.GetDate(out int year, out int month, out int day);
    Console.WriteLine("Date has been changed! Current date: " + year + "-" + month + "-" + day);
};