void DeleteAccount() { clsAccountsCollection AccountBook = new clsAccountsCollection(); AccountBook.ThisAccount.Find(AccountNr); AccountBook.Delete(); }
int Add() { clsAccountsCollection AccountBook = new clsAccountsCollection(); String Error = AccountBook.ThisAccount.Valid(txtAccountHolder.Text, BankName.Text, double.Parse(txtAccountNumber.Text)); if (Error == "") { AccountBook.ThisAccount.AccountHolder = txtAccountHolder.Text; AccountBook.ThisAccount.AccountNr = Int32.Parse(txtAccountNumber.Text); AccountBook.ThisAccount.AccountBank = BankName.Text; AccountBook.Add(); Response.Redirect("Payment_Details.aspx"); return(1); } else { Label2.Text = "There were problems with data entered" + Error; return(0); } }