Hi
Been trying to deleet an appointment, below is my back code for attempting to delete the appointment
When i put a brake point I see it doesnt even come near the event.
below is the code from my businesLayer
Been trying to deleet an appointment, below is my back code for attempting to delete the appointment
public void rsAppointments_AppointmentDelete(object sender, SchedulerCancelEventArgs e)
{
systemBusinessLayer.deleteAppointment(
Convert.ToInt32(e.Appointment.ID));
}
When i put a brake point I see it doesnt even come near the event.
below is the code from my businesLayer
public
void deleteAppointment(int appointmentID)
{
using (SqlConnection con = new SqlConnection(ConnString))
{
SqlCommand cmd = new SqlCommand("procDeleteAppointment", con);
cmd.CommandType =
CommandType.StoredProcedure;
cmd.Parameters.Add(
new SqlParameter("@appointmentID", SqlDbType.Int));
cmd.Parameters[
"@appointmentID"].Value = appointmentID;
try
{
con.Open();
cmd.ExecuteNonQuery();
}
catch (SqlException exp)
{
throw new ApplicationException(exp.Message);
}
}
}