예제 #1
0
    protected void txtrefcustname_TextChanged(object sender, EventArgs e)
    {
        try
        {
            string   CUNAME  = txtrefcustname.Text;
            string[] custnob = CUNAME.Split('_');
            if (custnob.Length > 1)
            {
                txtrefcustname.Text = custnob[0].ToString();
                Txtrefcustno.Text   = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());
                TxtAgentNo.Focus();
            }
            if (Txtrefcustno.Text == txtcstno.Text)
            {
                WebMsgBox.Show("Ref Customer No Cannot be same as Customer No", this.Page);
                txtrefcustname.Text = "";
                Txtrefcustno.Text   = "";

                Txtrefcustno.Focus();
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
예제 #2
0
 protected void Txtrefcustno_TextChanged(object sender, EventArgs e)
 {
     try
     {
         string sql, AT;
         sql = AT = "";
         string   custname = accop.Getcustname(Txtrefcustno.Text);
         string[] name     = custname.Split('_');
         txtrefcustname.Text = name[0].ToString();
         string RC = txtrefcustname.Text;
         TxtAgentNo.Focus();
         if (RC == "")
         {
             WebMsgBox.Show("Customer not found", this.Page);
             Txtrefcustno.Text = "";
             Txtrefcustno.Focus();
             return;
         }
         if (Txtrefcustno.Text == txtcstno.Text)
         {
             WebMsgBox.Show("Ref Customer No Cannot be same as Customer No", this.Page);
             Txtrefcustno.Text   = "";
             txtrefcustname.Text = "";
             Txtrefcustno.Focus();
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }
예제 #3
0
 protected void chkNo_CheckedChanged(object sender, EventArgs e)
 {
     dvminor.Visible = false;
     dvmname.Visible = false;
     dvmdate.Visible = false;
     Txtrefcustno.Focus();
 }