예제 #1
0
    /// <summary>
    /// 取得LocateSection,存入ViewState
    /// </summary>
    private void GetLocateSection()
    {
        try
        {
            string LocateNo = string.Empty;
            string LocateSection = string.Empty;

            PIC.VDS2G.GFM.INV.MaintainStockTmpLocate BCO = new PIC.VDS2G.GFM.INV.MaintainStockTmpLocate(ConntionDB);

            ParameterList.Clear();

            ParameterList.Add("D");

            BCO.QueryLocateByUse(ParameterList, out LocateNo, out LocateSection);

            if (LocateNo.Length == 0)
            {
                ErrorMsgLabel.Text = "請先設定門退入庫儲位";
                btnSearch.Enabled = false;
            }
            else
            {
                ViewState["LocateSection"] = LocateSection;
            }
        }
        catch (Exception ex)
        {
            if (ex.Message.IndexOf("請先設定此功能別對應的儲位") != -1)
            {
                ErrorMsgLabel.Text = "請先設定門退入庫儲位";
            }
            else
            {
                ErrorMsgLabel.Text = ex.Message;
            }
            btnSearch.Enabled = false;
            btnCancel.Enabled = false;
        }
    }
예제 #2
0
 public string GetDefaultLocateSecByUse(string LocateUse)
 {
     string LocateNo = string.Empty;
     string LocateSec = string.Empty;
     try
     {
         DBOINV.MaintainStockTmpLocate INVDBO = new DBOINV.MaintainStockTmpLocate(strConn);
         ArrayList ParameterList = new ArrayList();
         ParameterList.Add(LocateUse);
         INVDBO.QueryLocateByUse(ParameterList, out LocateNo, out LocateSec);
         return LocateSec;
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
예제 #3
0
 //取得廠退使用儲區(LocateSection)
 public void QueryTargetLocate(ArrayList ParameterList, out string LocateNo, out string LocateSection)
 {
     try
     {
         INVDBO.MaintainStockTmpLocate db = new INVDBO.MaintainStockTmpLocate(strConn);
         ParameterList.Clear();
         ParameterList.Add("B");
         db.QueryLocateByUse(ParameterList, out LocateNo, out LocateSection);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }