示例#1
0
文件: frmDelivery.cs 项目: cfmis/cfvn
 private void txtserial_no_Leave(object sender, EventArgs e)
 {
     if (txtserial_no.Text == "")
     {
         txtserial_name.Text = "";
         return;
     }
     if (mState == "NEW" || mState == "EDIT")
     {
         clsCityCode obj            = new clsCityCode();
         string      strSerial_name = obj.Get_City_Name(txtserial_no.Text);
         if (strSerial_name != "")
         {
             txtserial_name.Text = strSerial_name;
             if (dgvDetails.RowCount > 0)
             {
                 Set_cost_price();
                 Count_Head_Cost();
             }
         }
         else
         {
             txtserial_name.Text = "";
             txtamt_sum.Text     = "";
             MessageBox.Show("区域代码不存在!", "提示信息");
             txtserial_no.Focus();
         }
     }
 }
示例#2
0
 private void txtserial_no_Leave(object sender, EventArgs e)
 {
     if (txtserial_no.Text != "" && (mState == "NEW" || mState == "EDIT"))
     {
         clsCityCode obj            = new clsCityCode();
         string      strSerial_name = obj.Get_City_Name(txtserial_no.Text);
         if (strSerial_name != "")
         {
             txtSerial_name.Text = strSerial_name;
         }
         else
         {
             txtSerial_name.Text = "";
             MessageBox.Show("区域代码不存在!", "提示信息");
             txtserial_no.Focus();
         }
     }
 }