protected void TxtDPRDName_TextChanged(object sender, EventArgs e)
 {
     try
     {
         if (TxtDBRCD.Text != "")
         {
             string   custno = TxtDPRDName.Text;
             string[] CT     = custno.Split('_');
             if (CT.Length > 0)
             {
                 TxtDPRDName.Text = CT[0].ToString();
                 TxtDPRD.Text     = CT[1].ToString();
                 string[] GLS = BD.GetAccTypeGL(TxtDPRD.Text, TxtDBRCD.Text).Split('_');
                 ViewState["GL"]          = GLS[1].ToString();
                 autoglnameAC2.ContextKey = TxtDBRCD.Text + "_" + TxtDPRD.Text + "_" + ViewState["GL"].ToString();
             }
             TxtAcNoD.Focus();
         }
         else
         {
             WebMsgBox.Show("Enter Branch Code First....!", this.Page);
             TxtDPRDName.Text = "";
             TxtDBRCD.Focus();
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }
 protected void TxtDBRCD_TextChanged(object sender, EventArgs e)
 {
     try
     {
         if (TxtDBRCD.Text != "")
         {
             string bname = AST.GetBranchName(TxtDBRCD.Text);
             if (bname != null)
             {
                 TxtDBRCDname.Text = bname;
                 TxtDPRD.Focus();
             }
             else
             {
                 WebMsgBox.Show("Enter valid Branch Code.....!", this.Page);
                 TxtDBRCD.Text = "";
                 TxtDBRCD.Focus();
             }
         }
         else
         {
             WebMsgBox.Show("Enter Branch Code!....", this.Page);
             TxtDBRCD.Text = "";
             TxtDBRCD.Focus();
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }