public string CGDEMPName(string Vendor, string EMP_ID) { string Name = ""; string ConnectionDBStr = ((DatabaseSettings)ConfigurationManager.GetSection("dataConfiguration")).DefaultDatabase; CGD32_BCO bco = new CGD32_BCO(ConnectionDBStr); if (EMP_ID != "") { ArrayList ParameterList = new ArrayList(); ParameterList.Add(Vendor); ParameterList.Add(EMP_ID); ParameterList.Add(DBNull.Value); ParameterList.Add(DBNull.Value); ParameterList.Add(DBNull.Value); DataTable dt = bco.DoQueryEmpSLP(ParameterList); if (dt.Rows.Count > 0) { Name = dt.Rows[0]["EMP_NAME"].ToString().Trim(); } else { Name = "查無資料"; } } return Name; }
protected void ButtonQuery_Click(object sender, EventArgs e) { try { //清除目前選擇DATA this.lblVENDOR.Text = ""; this.lblVENDOR_NAME.Text = ""; CGD32_BCO bco = new CGD32_BCO(ConntionDB); firstpage = 0; firstindex = -1; databind(); } catch (Exception ex) { ErrorMsgLabel.Text = ex.Message; } finally { } }//ButtonQuery_Click
public SLP_CGDVENDOR() { bco = new CGD32_BCO(ConntionDB); }
public SLP_CGDEMP() { bco = new CGD32_BCO(ConntionDB); }