protected void Txtprdname_TextChanged(object sender, EventArgs e) { try { string CUNAME = Txtprdname.Text; string[] custnob = CUNAME.Split('_'); if (custnob.Length > 1) { Txtprdname.Text = custnob[0].ToString(); Txtprdcode.Text = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString()); string[] AC = LI.Getaccno(Txtprdcode.Text, Session["BRCD"].ToString()).Split('_'); ViewState["GLCODE"] = AC[0].ToString(); TxtFAmt.Focus(); } else { Txtprdcode.Focus(); return; } BindGrid("PA"); } catch (Exception Ex) { ExceptionLogging.SendErrorToText(Ex); } }
protected void Txtprdcode_TextChanged(object sender, EventArgs e) { try { string AC1; AC1 = LI.Getaccno(Txtprdcode.Text, Session["BRCD"].ToString()); if (AC1 != null) { string[] AC = AC1.Split('_');; ViewState["GLCODE"] = AC[0].ToString(); if (ViewState["GLCODE"].ToString() == "3") { Txtprdname.Text = AC[1].ToString(); TxtFAmt.Focus(); } else { WebMsgBox.Show("Enter only Loan Product Code....!", this.Page); Txtprdcode.Text = ""; Txtprdcode.Focus(); } } else { WebMsgBox.Show("Enter valid Product code...!!", this.Page); Txtprdcode.Text = ""; Txtprdcode.Focus(); return; } BindGrid("PA"); } catch (Exception Ex) { ExceptionLogging.SendErrorToText(Ex); } }