Пример #1
0
        private void DateButton_Click(object sender, EventArgs e)
        {
            var proxy = new NextThousandDaysClient();

            var date = dateBox.Text;

            ResultLabel.Text = proxy.DaysToGo(DateTime.Parse(date)).ToString();
        }
Пример #2
0
        static void Main(string[] args)
        {
            var proxy = new NextThousandDaysClient();

            Console.WriteLine("Provide your date of birth in a yyyy/mm/dd format:");

            var date = Console.ReadLine();

            var result = proxy.DaysToGo(DateTime.Parse(date));


            Console.WriteLine($"next time you have an even thousand days to your age is: {result.ToString()}");
            Console.ReadKey();
        }