示例#1
0
 private void button1_Click(object sender, EventArgs e)
 {
     lblResult.Text = "";
     var birthdate = dateTimePicker1.Value;
     ThousandDaysOldClient client = new ThousandDaysOldClient();
     var result = client.GetNextDateForThousandYearBirthday(birthdate.ToString());
     lblResult.Text = result.Date.ToString();
 }
示例#2
0
        private void button1_Click(object sender, EventArgs e)
        {
            lblResult.Text = "";
            var birthdate = dateTimePicker1.Value;
            ThousandDaysOldClient client = new ThousandDaysOldClient();
            var result = client.GetNextDateForThousandYearBirthday(birthdate.ToString());

            lblResult.Text = result.Date.ToString();
        }
示例#3
0
        static void Main(string[] args)
        {
            Console.WriteLine("Enter Your Birthdate (19xx,xx,xx)");
            var date = Console.ReadLine();

            var client = new ThousandDaysOldClient();
            var result = client.GetNextDateForThousandYearBirthday(date);

            Console.WriteLine($"Your next thousand day birthday is at {result.ToShortDateString().ToString()}");
            Console.ReadLine();
        }