protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { DataView dv = new DataView(BindGvCustDetail().Table); Session["data"] = dv; grdCustDetails.DataSource = dv; grdCustDetails.DataBind(); DdlSection.Enabled = false; DdlSection.DataSource = SectionMaster.Get_SectionList(); DdlSection.DataBind(); repAlfabets.DataSource = Customer_cs.GetAlphabets(); repAlfabets.DataBind(); LblCustId.Text = "0"; fillzones(); TxtCustCode.Focus(); custRating(); getDDLdata(); getDDLarezo(); getDDLarea(); SetView(); //dv = (DataView)Session["data"]; ////string val = ((LinkButton)(sender)).Text; //dv.RowFilter = "CustName='A'"; //grdCustDetails.DataSource = dv; //grdCustDetails.DataBind(); //((LinkButton)(sender)).BackColor = System.Drawing.Color.Red; //((LinkButton)(sender)).ForeColor = System.Drawing.Color.White; } }
protected void TxtCustCode_TextChanged(object sender, EventArgs e) { bool Auth = Masters.GetCodeValidation("Customer", TxtCustCode.Text.Trim()); if (Auth) { MessageBox("Customer Code already exist"); TxtCustCode.Text = ""; TxtCustCode.Focus(); } else { TxtCustName.Focus(); } }
protected void Page_Load(object sender, EventArgs e) { if (ChkBlacklist.Checked == true) { lblblkremark.Visible = true; LblblkDate.Visible = true; TxtblkRemark.Visible = true; TxtblkDate.Visible = true; } else { lblblkremark.Visible = false; LblblkDate.Visible = false; TxtblkRemark.Visible = false; TxtblkDate.Visible = false; } if (Session["ChetanaCompanyName"] != "" || Session["ChetanaCompanyName"] != null) { if (Session["FY"] != "" || Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); } } if (!Page.IsPostBack) { btnAddAccess.Enabled = false; txtBookType.Enabled = false; txtFromQty.Enabled = false; txtToQty.Enabled = false; txtDiscount.Enabled = false; DdlSection.Enabled = false; DdlSection.DataSource = SectionMaster.Get_SectionList(); DdlSection.DataBind(); repAlfabets.DataSource = Customer_cs.GetAlphabets(); repAlfabets.DataBind(); LblCustId.Text = "0"; fillzones(); custRating(); getDDLdata(); getDDLarezo(); getDDLarea(); GetSBUCode(); Session["saved"] = null; Session["TempDataTable"] = null; Session["TempAssorted"] = null; checkAction.Checked = true; SetView(); TxtCustCode.Focus(); if (ChkBlacklist.Checked == true) { lblblkremark.Visible = true; LblblkDate.Visible = true; TxtblkRemark.Visible = true; TxtblkDate.Visible = true; } else { lblblkremark.Visible = false; LblblkDate.Visible = false; TxtblkRemark.Visible = false; TxtblkDate.Visible = false; } } }