Example #1
0
        public void openRFPqcFrm()
        {
            RFPqcFrm frm = new RFPqcFrm(this.loginuser, null, this.pqcpeoplenum.Text, this.asnlist01res.AdvancedShipNoticeHeaders[0].AdvancedShipNoticeDetail);
            DialogResult result = frm.ShowDialog();
            if (result == DialogResult.OK)
            {
               string linenum = frm.currlinenum;
                if (!string.IsNullOrEmpty(linenum))
                {
                    for (int i = 0; i < asnlist.Items.Count; i++)
                    {
                        string l = (string)asnlist.Items[i];
                        if (l.ToString().IndexOf(linenum) >= 0)
                        {
                            this.asnlist.Items.Remove(asnlist.Items[i]);
                            break;
                        }
                    }
                }

                if (this.asnlist.Items.Count == 0)
                {
                    this.inputopenbox();
                }
            }
        }
Example #2
0
 private void asnlist_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (this.asnlist.SelectedItem != null)
     {
         string str = this.asnlist.SelectedItem.ToString();
         string[] arr = str.Split(new char[] { ' ' });
         string linenum = arr[0];
         asnlist01_res.AdvancedShipNoticeDetail seleted=null;
         foreach (asnlist01_res.AdvancedShipNoticeDetail detaill in this.asnlist01res.AdvancedShipNoticeHeaders[0].AdvancedShipNoticeDetail)
         {
             if (linenum == detaill.ReceiptLineNumber)
             {
                 seleted = detaill;
                 break;
             }
         }
         RFPqcFrm frm = new RFPqcFrm(this.loginuser, seleted, this.pqcpeoplenum.Text, this.asnlist01res.AdvancedShipNoticeHeaders[0].AdvancedShipNoticeDetail);
         DialogResult result = frm.ShowDialog();
         if (result == DialogResult.OK)
         {
             linenum = frm.currlinenum;
             if (!string.IsNullOrEmpty(linenum))
             {
                 for (int i = 0; i < asnlist.Items.Count;i++ )
                 {
                     string l = (string)asnlist.Items[i];
                     if (l.ToString().IndexOf(linenum) >= 0)
                     {
                         this.asnlist.Items.Remove(asnlist.Items[i]);
                         break;
                     }
                 }
             }
             if (this.asnlist.Items.Count == 0)
             {
                 this.inputopenbox();
             }
         }
     }
 }