private void btnAdopt_Click(object sender, EventArgs e) { Owner AnOwner = myShelter.GetOwner(tbEmail_ACpn.Text); if (AnOwner != null) { if (myAnimal.Adopt(AnOwner, ref feeCalculated)) { MessageBox.Show("The adoption is successful. The adoption fee is " + feeCalculated); } else { MessageBox.Show("The adoption is unsuccessful"); } } else { MessageBox.Show("This owner is not existed"); } }