internal DataTable DL_SaveLicPolicy(PL_LicPolicy plobj) { try { con = Connection.SetConnection(); cmd = new SqlCommand("SPLICPolicyentry", con); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@Ind", plobj.Ind); cmd.Parameters.AddWithValue("@EmpNo", plobj.EmpNo); cmd.Parameters.AddWithValue("@PolicyNo", plobj.PolicyNo); cmd.Parameters.AddWithValue("@PolicyAmt", plobj.PolicyAmt); cmd.Parameters.AddWithValue("@PolicyType", plobj.PolicyType); cmd.Parameters.AddWithValue("@PolicyTypeDese", plobj.PolicyTypeDese); cmd.Parameters.AddWithValue("@Installment", plobj.Installment); cmd.Parameters.AddWithValue("@StartDate", plobj.StartDate); cmd.Parameters.AddWithValue("@MaturityDate", plobj.MaturityDate); cmd.Parameters.AddWithValue("@DivCode", plobj.DivCode); cmd.Parameters.AddWithValue("@DivCodeDese", plobj.DivCodeDese); cmd.Parameters.AddWithValue("@Stop", plobj.Stop); cmd.Parameters.AddWithValue("@EDCD", plobj.Edcd); cmd.Parameters.AddWithValue("@EDDesc", plobj.EDDesc); cmd.Parameters.AddWithValue("@Month", plobj.Month); cmd.Parameters.AddWithValue("@CityCode", plobj.citycode); da = new SqlDataAdapter(cmd); dt = new DataTable(); da.Fill(dt); return(dt); } catch { return(dt); } finally { con.Close(); con.Dispose(); } }
public DataTable Delete_PolicyType(PL_LicPolicy plobj) { DL_LicPolicy objdl = new DL_LicPolicy(); DataTable dt = new DataTable(); if (plobj.Ind == 0) { return dt; } else { dt = objdl.DL_DeleteLicPolicy(plobj); return dt; } }
internal DataTable DL_DeleteLicPolicy(PL_LicPolicy plobj) { try { con = Connection.SetConnection(); cmd = new SqlCommand("SPLICPolicyentry", con); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@Ind", plobj.Ind); cmd.Parameters.AddWithValue("@EmpNo", plobj.EmpNo); cmd.Parameters.AddWithValue("@PolicyNo", plobj.PolicyNo); cmd.Parameters.AddWithValue("@Month", plobj.Month); cmd.Parameters.AddWithValue("@CityCode", plobj.citycode); da = new SqlDataAdapter(cmd); dt = new DataTable(); da.Fill(dt); return(dt); } catch { return(dt); } finally { con.Close(); con.Dispose(); } }