コード例 #1
0
ファイル: ExcelExport.cs プロジェクト: jimidzj/Inspect
        private System.Data.DataTable GetReceivingDetail(string orderNo)
        {
            wsINP.IwsINPClient client = new wsINP.IwsINPClient();
            System.Data.DataTable dt =null;
            try
            {
                List<MESParameterInfo> lstParameters = new List<MESParameterInfo>();
                lstParameters.Add(new MESParameterInfo()
                {
                    ParamName = "custorderno",
                    ParamValue = orderNo,
                    ParamType = "string"
                });
               dt = client.GetReceivingDetailRecords(baseForm.CurrentContextInfo, lstParameters.ToArray<MESParameterInfo>()).Tables[0];

            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                baseForm.CloseWCF(client);
            }
            return dt;
        }
コード例 #2
0
ファイル: frmSupplement.cs プロジェクト: jimidzj/Inspect
 private bool isExistOrder(string customerid, string custorderno)
 {
     wsINP.IwsINPClient client = new wsINP.IwsINPClient();
     bool result=false;
     try
     {
         baseForm.SetCursor();
         List<MESParameterInfo> lstParameters = new List<MESParameterInfo>();
         lstParameters.Add(new MESParameterInfo()
         {
             ParamName = "customerid",
             ParamValue = customerid,
             ParamType = "string"
         });
         lstParameters.Add(new MESParameterInfo()
         {
             ParamName = "custorderno",
             ParamValue = custorderno,
             ParamType = "string"
         });
         DataSet ds = client.GetReceivingDetailRecords(baseForm.CurrentContextInfo, lstParameters.ToArray<MESParameterInfo>());
         if (ds.Tables[0].Rows.Count > 0)
         {
             result = true;
         }
         else
         {
             result = false;
         }
     }
     catch (Exception ex)
     {
         throw ex;
     }
     finally
     {
         baseForm.ResetCursor();
         baseForm.CloseWCF(client);
     }
     return result;
 }