private void addBtn_Click(object sender, EventArgs e) { COACHATTENDANCE coachAtten = new COACHATTENDANCE(); string fname = textBoxFname.Text; string lname = textBoxLname.Text; DateTime date = dateTimePicker1.Value; string swimT = textBoxSwmT.Text; string arrTime = textBoxArrival.Text; string sessTaught = textBoxSession.Text; if (verif()) { if (coachAtten.insertCoachAtten(fname, lname, date, swimT, arrTime, sessTaught)) { MessageBox.Show("Coach Attendance Added", "Add Coach Attendance", MessageBoxButtons.OK, MessageBoxIcon.Information); } else { MessageBox.Show("Error", "Add Coach Attendance", MessageBoxButtons.OK, MessageBoxIcon.Exclamation); } } }