Пример #1
0
        private void LoadData()
        {
            customer1 = new Customer();
            customer1.Id = 1;
            customer1.Name = "John Smith";

            customer2 = new Customer();
            customer2.Id = 2;
            customer2.Name = "Tom Jones";

            currentCustomer = customer1;
        }
Пример #2
0
 private void nextButton_Click(object sender, EventArgs e)
 {
     currentCustomer = (currentCustomer.Id != 1) ? customer1 : customer2;
 }