public ArrayList CustomermissindDatagetting(long?CustomerCustID, string strSpname) { DataSet dsMissingfields = new DataSet(); SqlDataAdapter daParentDetails = new SqlDataAdapter(); SqlConnection connection = new SqlConnection(); connection = SQLHelper.GetSQLConnection(); connection.Open(); try { SqlCommand cmd = new SqlCommand(strSpname, connection); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@CustomerCustID", CustomerCustID); daParentDetails.SelectCommand = cmd; daParentDetails.Fill(dsMissingfields); } catch (Exception Ex) { Commonclass.ApplicationErrorLog(strSpname, Convert.ToString(Ex.Message), @CustomerCustID, null, null); } finally { connection.Close(); } return(Commonclass.convertdataTableToArrayList(dsMissingfields)); }
public ArrayList DgetProfilePaymentDetails(long?intProfileID, int?Isonline, int?flag, int?intMembershipID, string taxpaid) { int? intStatus = 0; DataSet dsPayment = new DataSet(); SqlConnection connection = new SqlConnection(); connection = SQLHelper.GetSQLConnection(); connection.Open(); SqlParameter[] parm = new SqlParameter[7]; try { parm[0] = new SqlParameter("@ProfileID", SqlDbType.BigInt); parm[0].Value = intProfileID; parm[1] = new SqlParameter("@flag", SqlDbType.Int); parm[1].Value = flag; parm[2] = new SqlParameter("@MemberShipID", SqlDbType.Int); parm[2].Value = intMembershipID; parm[3] = new SqlParameter("@Isonline", SqlDbType.Int); parm[3].Value = Isonline; parm[4] = new SqlParameter("@Status", SqlDbType.Int); parm[4].Direction = ParameterDirection.Output; parm[5] = new SqlParameter("@ErrorMsg", SqlDbType.VarChar, 1000); parm[5].Direction = ParameterDirection.Output; parm[6] = new SqlParameter("@taxpaid", SqlDbType.VarChar, 1000); parm[6].Value = taxpaid; dsPayment = SQLHelper.ExecuteDataset(connection, CommandType.StoredProcedure, "usp_Payment_getProfilePaymentDetails", parm); if (string.Compare(System.DBNull.Value.ToString(), parm[4].Value.ToString()) == 0) { intStatus = 0; } else { intStatus = Convert.ToInt32(parm[4].Value); } } catch (Exception EX) { Commonclass.ApplicationErrorLog("usp_Payment_getProfilePaymentDetails", Convert.ToString(EX.Message), Convert.ToInt32(intProfileID), null, null); } finally { connection.Close(); } if (dsPayment.Tables.Count == 0) { dsPayment = null; } return(Commonclass.convertdataTableToArrayList(dsPayment)); }
public ArrayList DgetProfilePaymentDetails_NewDesigns(string intProfileID, int intPaymentHistID, string spName) { int? intStatus = 0; DataSet dsPayment = new DataSet(); SqlConnection connection = new SqlConnection(); connection = SQLHelper.GetSQLConnection(); connection.Open(); SqlParameter[] parm = new SqlParameter[4]; try { parm[0] = new SqlParameter("@ProfileID", SqlDbType.BigInt); parm[0].Value = !string.IsNullOrEmpty(intProfileID) ? Convert.ToInt64(intProfileID) : 0; parm[1] = new SqlParameter("@intPaymentHistID", SqlDbType.Int); parm[1].Value = intPaymentHistID; parm[2] = new SqlParameter("@Status", SqlDbType.Int); parm[2].Direction = ParameterDirection.Output; parm[3] = new SqlParameter("@ErrorMsg", SqlDbType.VarChar, 1000); parm[3].Direction = ParameterDirection.Output; dsPayment = SQLHelper.ExecuteDataset(connection, CommandType.StoredProcedure, spName, parm); if (string.Compare(System.DBNull.Value.ToString(), parm[1].Value.ToString()) == 0) { intStatus = 0; } else { intStatus = Convert.ToInt32(parm[1].Value); } } catch (Exception EX) { Commonclass.ApplicationErrorLog(spName, Convert.ToString(EX.Message), Convert.ToInt32(intProfileID), null, null); } finally { connection.Close(); } if (dsPayment.Tables.Count == 0) { dsPayment = null; } return(Commonclass.convertdataTableToArrayList(dsPayment)); }
public ArrayList DGetloginCustinformation(string Username, string Password, int?iflag) { DataSet dataSet = new DataSet(); SqlDataAdapter dataAdapter = new SqlDataAdapter(); SqlConnection connection = new SqlConnection(); connection = SQLHelper.GetSQLConnection(); connection.Open(); int status = 0; try { SqlCommand cmd = new SqlCommand("[dbo].[Usp_CheckCustLogin]", connection); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@Username", Username); cmd.Parameters.AddWithValue("@Password", Password); cmd.Parameters.AddWithValue("@iflag", iflag); SqlParameter outputParamStatus = cmd.Parameters.Add("@Status", SqlDbType.Int); outputParamStatus.Direction = ParameterDirection.Output; dataAdapter.SelectCommand = cmd; dataAdapter.Fill(dataSet); if (Convert.ToInt32(cmd.Parameters[2].Value) == 1) { status = 1; } else { status = 0; } } catch (Exception EX) { Commonclass.ApplicationErrorLog("Usp_CheckCustLogin", Convert.ToString(EX.Message), null, null, null); } finally { connection.Close(); } return(Commonclass.convertdataTableToArrayList(dataSet)); }