public void updateCustomerDialog(CustomerDialog cd, ListCustomersDialog lcd) { cd.FirstName = listOfCustomers[lcd.SelectedIndex].firstName; cd.LastName = listOfCustomers[lcd.SelectedIndex].lastName; cd.UserName = listOfCustomers[lcd.SelectedIndex].userName; cd.Password = listOfCustomers[lcd.SelectedIndex].password; cd.EMailAddress = listOfCustomers[lcd.SelectedIndex].email; cd.Address = listOfCustomers[lcd.SelectedIndex].address; cd.TelephoneNumber = listOfCustomers[lcd.SelectedIndex].phoneNumber; }
// XXX You may add overriding constructors (constructors with different set of arguments). // If you do so, make sure to call :this() // public StaffWindow(XXX xxx): this() { } // Without :this(), InitializeComponent() is not called private void StaffWindow_Load(object sender, EventArgs e) { listCustomersDialog = new ListCustomersDialog(); customerDialog = new CustomerDialog(); listBooksDialog = new ListBooksDialog(); bookDialog = new BookDialog(); listCompleteTransactionsDialog = new ListCompleteTransactionsDialog(); showCompleteTransactionDialog = new ShowCompleteTransactionDialog(); listPendingTransactionsDialog = new ListPendingTransactionsDialog(); showPendingTransactionDialog = new ShowPendingTransactionDialog(); }
public void ListCustomers(ref ListCustomersDialog lc) { lc.AddDisplayItems(customers.ToArray()); }