コード例 #1
0
 public string SelectChargeDetailsByID(string strChargeId)
 {
     try
     {
         DALComponent objDAL = new DALComponent();
         objDAL.SetParameters("@chargeId", SqlDbType.Int, 4, Convert.ToInt32(strChargeId));
         objDAL.SqlCommandText = "SelectChargeDetailsByID";
         return GetJson(objDAL.SelectRecord());
     }
     catch (SqlException sqlEx)
     {
         throw new ApplicationException("Data error=" + sqlEx.Message.ToString());
     }
     catch (Exception ex)
     {
         throw new ApplicationException("Error=" + ex.Message.ToString());
     }
 }
コード例 #2
0
 public DataTable GetAdDetailsDT(UserAdpost adpostDetails)
 {
     try
     {
         DALComponent objDALComponent1 = new DALComponent();
         objDALComponent1.SetParameters("@adpostId", SqlDbType.Int, 4, adpostDetails.AdPostId);
         objDALComponent1.SetParameters("@userId", SqlDbType.Int, 4, adpostDetails.UserId);
         objDALComponent1.SqlCommandText = "[GetAdDetails]";
         return objDALComponent1.SelectRecord();
     }
     catch (SqlException sqlEx)
     {
         throw new ApplicationException("Data error=" + sqlEx.Message.ToString());
     }
     catch (Exception ex)
     {
         throw new ApplicationException("Error=" + ex.Message.ToString());
     }
 }
コード例 #3
0
 public string GetAdPurcDetails(string sAdPostID, string sAdUserID)
 {
     try
     {
         DALComponent objDAL = new DALComponent();
         objDAL.SetParameters("@adpostId", SqlDbType.Int, 4, Convert.ToInt32(sAdPostID));
         objDAL.SetParameters("@userId", SqlDbType.Int, 4, Convert.ToInt32(sAdUserID));
         objDAL.SqlCommandText = "[GetAdPurcDetails]";
         string s = GetJson(objDAL.SelectRecord());
         return s;
     }
     catch (SqlException sqlEx)
     {
         return sqlEx.Message.ToString();
     }
     catch (Exception ex)
     {
         return ex.Message.ToString();
     }
 }
コード例 #4
0
 public string AvailableMail(string strEmail)
 {
     try
     {
         DALComponent objDAL = new DALComponent();
         objDAL.SetParameters("@email", SqlDbType.VarChar, 50, strEmail);
         objDAL.SqlCommandText = "[AvailableMail]";
         return GetJson(objDAL.SelectRecord());
     }
     catch (SqlException sqlEx)
     {
         throw new ApplicationException("Data error=" + sqlEx.Message.ToString());
     }
     catch (Exception ex)
     {
         throw new ApplicationException("Error=" + ex.Message.ToString());
     }
 }