public void Bind_DDL_SuperZone() { //Response.Write(Convert.ToInt32(ddlSDZone.SelectedValue.ToString())); DDlZone.Items.Clear(); DDLSuperZone.Items.Clear(); DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(ddlSDZone.SelectedValue.ToString()), "SuperZone1"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); DDlZone.Items.Insert(0, new ListItem("-Select Zone-", "0")); }
public void Bind_DDL_SuperZone() { DDLSuperZone.Items.Clear(); if (ddlSDZone.SelectedIndex != 0) { DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(ddlSDZone.SelectedValue.ToString()), "SuperZone1"); DDLSuperZone.DataBind(); DDLSuperZone.Focus(); } DDLSuperZone.Items.Insert(0, new ListItem("-All Super Zone-", "0")); }
public void Bind_DDL_Zone() { DDLZone.Items.Clear(); if (DDLSuperZone.SelectedIndex != 0) { DDLZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLSuperZone.SelectedValue.ToString()), "Zone"); DDLZone.DataBind(); DDLZone.Items.Insert(0, new ListItem("-All Zone-", "0")); DDLZone.Focus(); } ddlCustmore.Items.Clear(); ddlCustmore.Items.Insert(0, new ListItem("-All Customer-", "0")); }
public void Bind_DDL_SuperZone() { //DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); //DDLSuperZone.DataBind(); //DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); //DDLZone.Items.Insert(0, new ListItem("-Select Zone-", "0")); DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(ddlSDZone.SelectedValue.ToString()), "SuperZone1"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-- Select SuperZone --", "0")); DDLZone.Items.Insert(0, new ListItem("--All--", "0")); //DDLSuperZone.Focus(); }
protected void Page_Load(object sender, EventArgs e) { if (Session["FY"] != null) { // strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); // HidFY.Value = Session["FY"].ToString(); //DateTime now = DateTime.Now; //now.ToString("dd/MM/yyyy"); //txtFromDate.Text = new DateTime(now.Year, 1, now.Month).ToShortDateString(); //txttoDate.Text = new DateTime(now.AddMonths(1).Year, now.AddMonths(1).Month, 1).ToShortDateString(); //todate = txttoDate.Text.Split('/')[1] + "/" + txttoDate.Text.Split('/')[0] + "/" + txttoDate.Text.Split('/')[2]; //txttoDate.Text = todate; btnexport.Visible = false; } else { Session.Clear(); } if (!Page.IsPostBack) { //SetView(); // BindBankRDetails(); // DDLCCDD.Items.Insert(0, new ListItem("-Select-", "0")); //txtFromDate.Text = "01/04/201" + Convert.ToInt32(Session["FY"]).ToString(); //txttoDate.Text = -"31/03/201" + Convert.ToInt32(Convert.ToInt32(Session["FY"]) + 1); DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("All Super Zone-", "0")); //txtbankcoder.Focus(); Session["Data"] = null; } else { if (rdWeek.Checked) { if (Session["Data"] != null) { FillReport((DataView)Session["Data"]); } } else { collectionReportView.Visible = false; } } }
protected void DDLsuperzone_SelectedIndexChanged(object sender, EventArgs e) { DDLzone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLsuperzone.SelectedValue.ToString()), "Zone"); DDLzone.DataBind(); DDLzone.Items.Insert(0, new ListItem("All", "0")); DDLzone.Enabled = true; if (DDLsuperzone.SelectedValue == "0") { DDLzone.SelectedValue = "0"; DDLareazone.SelectedValue = "0"; // DDLarea.SelectedValue = "0"; } DDLzone.Focus(); }
protected void ddlSDZone_SelectedIndexChanged(object sender, EventArgs e) { if (ddlSDZone.SelectedIndex == 0) { DDLSuperZone.Items.Clear(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); } else { DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(ddlSDZone.SelectedValue.ToString()), "SuperZone1"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-- Select SuperZone --", "0")); DDLSuperZone.Focus(); } }
protected void ddlSDZone_SelectedIndexChanged(object sender, EventArgs e) { if (ddlSDZone.SelectedIndex == 0) { ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Focus(); DDLSuperZone.Items.Clear(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); } else { Bind_DDL_SuperZone(); DDLSuperZone.Focus(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null) { if (Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); } } if (!Page.IsPostBack) { GetValidation(4, Convert.ToInt32(Session["Role"])); docno.InnerHtml = "Not Selected"; DDLCustomer.Focus(); DDLCustomer.TabIndex = 0; Pnldeldate.Visible = false; pnlcity.Visible = false; Pnlcust.Visible = true; pnlDetails.Visible = false; Rptrpending.Visible = true; upOrderNO.Update(); pnlconfirm.Visible = false; if (Request.QueryString["c"] != null) { DDLCustomer.SelectedValue = Request.QueryString["c"].ToString(); fillData(); } ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Focus(); setddl(Session["zoneLevel"].ToString(), Session["zoneId"].ToString()); lblFY.Text = strFY; } if (add) { btnconfirm.Enabled = true; } if (view) { btnget.Enabled = true; } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { LblEmpID.Visible = false; DdlRole.DataSource = Rolemaster.Get_RoleMaster(); DdlRole.DataBind(); fillQualification(); fillDesignation(); PnlLoginDetails.Visible = false; grdEmpDetails.DataSource = BindGvEmpDetail(); grdEmpDetails.DataBind(); // // DDLsuperzone.DataSource = SuperZone.GetSuperzonemaster(); // DDLsuperzone.DataBind(); DDLSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); DDLSDZone.DataBind(); DDLSDZone.Items.Insert(0, new ListItem("All", "0")); DDLsuperzone.Items.Insert(0, new ListItem("All", "0")); DDLzone.Items.Insert(0, new ListItem("All", "0")); DDLareazone.Items.Insert(0, new ListItem("All", "0")); // DDLarea.Items.Insert(0, new ListItem("All", "0")); // DDLstate.DataSource = Customer_cs.Get_DestinationMaster("state"); DDLstate.DataBind(); DDLstate.Items.Insert(0, new ListItem("--Select State--", "0")); DDLcity.Items.Insert(0, new ListItem("--Select City--", "0")); SetView(); // txtjoin.Text = DateTime.Now.ToString("dd/MM/yyyy"); txtResign.Text = "30/01/2050"; EmpId(); } else { } }
protected void RdbtnSelect1_SelectedIndexChanged(object sender, EventArgs e) { if (RdbtnSelect1.SelectedValue == "Summary") { Pnl2.Visible = true; Pnl1.Visible = false; Pnl3.Visible = false; Response.Redirect(Request.RawUrl); } if (RdbtnSelect1.SelectedValue == "Details") { Pnl2.Visible = false; Pnl3.Visible = false; Pnl1.Visible = true; DDLSuperZone.Focus(); DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); getDDLdata(); txtfromDate.Text = Session["FromDate"].ToString(); txtToDate.Text = Session["ToDate"].ToString(); DDLCC.DataSource = Idv.Chetana.BAL.CustCategory.GetCustomerCategoryMaster("adminCCM"); DDLCC.DataBind(); DDLCC.Items.Insert(0, new ListItem("--Select Category--", "0")); DDLCC.Enabled = true; } if (RdbtnSelect1.SelectedValue == "Summary-Excel") { Pnl2.Visible = false; Pnl1.Visible = false; Pnl3.Visible = true; ddlSDZone.Focus(); Bind_DDl_SDZone(); //DDLSuperZone1.Focus(); //DDLSuperZone1.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); //DDLSuperZone1.DataBind(); //DDLSuperZone1.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); //getDDLdata1(); txtfromDate1.Text = Session["FromDate"].ToString(); txtToDate1.Text = Session["ToDate"].ToString(); } }
protected void ddlSDZone_SelectedIndexChanged(object sender, EventArgs e) { if (ddlSDZone.SelectedIndex == 0) { // MessageBox("Select SuperZone"); ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Focus(); DDLsuperzone.Items.Clear(); DDLsuperzone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); // DDLZone.SelectedValue = null; // Bind_DDL_ZoneCust(); } else { Bind_DDL_SuperZone(); DDLsuperzone.Focus(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null) { if (Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); HidFY.Value = Session["FY"].ToString(); } else { Session.Clear(); } //Response.Write(strFY); } if (!Page.IsPostBack) { //SetView(); // BindBankRDetails(); // DDLCCDD.Items.Insert(0, new ListItem("-Select-", "0")); ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Items.Insert(0, new ListItem("-Select Super Duper Zone-", "0")); ddlSDZone.Focus(); DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); //txtbankcoder.Focus(); Session["Data"] = null; } else { if (Session["Data"] != null) { FillReport((DataView)Session["Data"]); } } }
protected void ddlSDZone_SelectedIndexChanged(object sender, EventArgs e) { if (ddlSDZone.SelectedIndex == 0) { // MessageBox("Select SuperZone"); lblsdzselect.Visible = true; lblsdzselect.Text = "Selected : " + ddlSDZone.SelectedItem.Text.ToString(); DDLSuperZone.Items.Clear(); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); // DDLZone.SelectedValue = null; // Bind_DDL_ZoneCust(); } else { DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(ddlSDZone.SelectedValue.ToString()), "SuperZone1"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-- Select SuperZone --", "0")); DDLSuperZone.Focus(); //lblsdzselect.Visible = true; lblsdzselect.Text = "Selected : " + ddlSDZone.SelectedItem.Text.ToString(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null) { if (Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); } } if (!Page.IsPostBack) { ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Focus(); setddl(Session["zoneLevel"].ToString(), Session["zoneId"].ToString()); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null) { if (Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); } //Response.Write(strFY); if (!Page.IsPostBack) { DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-Select SuperZone-", "0")); txtfromDate.Focus(); } } }
protected void Page_Load(object sender, EventArgs e) { if (Session["FY"] != null) { strFY = Session["FY"].ToString(); } else { Session.Clear(); } if (!Page.IsPostBack) { ddlSDZone.Focus(); ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Items.Insert(0, new ListItem("-Select Super Duper Zone-", "0")); DDLsuperzone.Focus(); setdefaultdate(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null && Session["FY"] != null || Session["FromDate"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); Response.Redirect("_auth.aspx"); } if (!Page.IsPostBack) { Session["CollectionGrpReportDocument"] = null; Session["CollectionGrpRptData"] = null; setdefaultdate(); DdlSpZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DdlSpZone.DataBind(); DdlSpZone.Items.Insert(0, new ListItem("All Super Zone-", "0")); //Bind_DDL_SuperDuperZone(); //ddlSDZone.Focus(); } else { //if (ViewState["strSelectedSD"] != null && ViewState["strSelectedSD"].ToString() != ddlSDZone.SelectedValue.ToString()) //{ // DDLSuperZone.SelectedIndex = 0; //} } if (txtIsExport.Value == "yes") { Bind(); txtIsExport.Value = ""; } }
public void Bind_DDL_Zone() { DDLZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLSuperZone.SelectedValue.ToString()), "Zone"); DDLZone.DataBind(); DDLZone.Items.Insert(0, new ListItem("--All--", "0")); }
//#region Text changed event //protected void txtCust_TextChanged(object sender, EventArgs e) //{ // callTextChange(); //} //protected void btnAddRecords_Click(object sender, EventArgs e) //{ // grdTemp.DataSource = fillTempBookData(txtCust.Text.ToString().Split(':')[0].Trim()); // grdTemp.DataBind(); // clearStrip(); // txtCust.Focus(); //} //#endregion //#region cust Text Change //public void callTextChange() //{ // string CustCode = txtCust.Text.ToString().Split(':')[0].Trim(); // DataTable dt = new DataTable(); // dt = DCMaster.Get_Name(CustCode, "Customer").Tables[0]; // if (dt.Rows.Count != 0) // { // if (Convert.ToString(dt.Rows[0]["BlackList"]).ToLower() != "true") // { // lblCustomer.Text = Convert.ToString(dt.Rows[0]["CustName"]); // txtCust.Text = CustCode; // lblCustID.Text = Convert.ToString(dt.Rows[0]["CustID"]); // txtCust.Focus(); // } // else // { // lblCustomer.Text = "Customer is blacklisted"; // txtCust.Focus(); // txtCust.Text = ""; // } // } // else // { // lblCustomer.Text = "No such Customer code"; // txtCust.Focus(); // txtCust.Text = ""; // } //} //#endregion //public void clearStrip() //{ // txtCust.Text = ""; // lblCustomer.Text = ""; // lblCustID.Text = ""; //} //protected void btnClearEdit_Click(object sender, EventArgs e) //{ // clearStrip(); //} //#region TEMP DATA //public DataTable fillTempBookData(string Cust) //{ // DataTable dt1 = new DataTable(); // dt1 = DCMaster.Get_Name(Cust, "Customer").Tables[0]; // DataTable dt = new DataTable(); // if (Session["getpasstempdata"] == null) // { // //CREATE NEW DATATABLE // dt.Columns.Add("SCHL_ID"); // dt.Columns.Add("SCHL_NAME"); // dt.Columns.Add("SCHL_AREA"); // dt.Columns.Add("ID"); // } // else // { // dt = (DataTable)Session["getpasstempdata"]; // } // dt.Rows.Add(dt1.Rows[0]["CustCode"].ToString(), dt1.Rows[0]["CustName"].ToString(), dt1.Rows[0]["AreaName"].ToString(), dt1.Rows[0]["CustID"].ToString()); // Session["getpasstempdata"] = dt; // return dt; //} //#endregion //#region MsgBox //public void MessageBox(string msg) //{ // string jv = "alert('" + msg + "');"; // ScriptManager.RegisterClientScriptBlock(Page, Page.GetType(), "msg", jv, true); //} //public void loder(string msg, string timetohid) //{ // string jv = "autosloder('" + msg + "'," + timetohid + ");"; // ScriptManager.RegisterClientScriptBlock(Page, Page.GetType(), "msg", jv, true); //} //#endregion //#region Delete temp data //protected void grdTemp_RowDeleting(object sender, GridViewDeleteEventArgs e) //{ // DataTable dt1 = new DataTable(); // dt1 = (DataTable)Session["getpasstempdata"]; // dt1.Rows[e.RowIndex].Delete(); // grdTemp.DataSource = dt1; // grdTemp.DataBind(); // upDetails.Update(); // Session["getpasstempdata"] = dt1; // loder("Successfully Deleted...", "3000"); //} //#endregion public void Bind_DDL_SuperZone() { DDLSuperZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SuperZone"); DDLSuperZone.DataBind(); DDLSuperZone.Items.Insert(0, new ListItem("-Select SuperZone-", "0")); }
protected void grdCustDetails_RowEditing(object sender, GridViewEditEventArgs e) { try { DDLareazone.Enabled = true; DDLarea.Enabled = true; DDLzone.Enabled = true; btnSave.Visible = true; btnSave.Text = "Update"; filter.Visible = false; btnSave.Enabled = true; PnlDetails.Visible = false; PnlAdd.Visible = true; repAlfabets.Visible = false; TxtCustCode.Enabled = false; LblCustId.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblCustID")).Text; TxtCustCode.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblCustCode")).Text; TxtShortForm.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblShortForm")).Text; TxtFamilyCode.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblFamilyCode")).Text; TxtAddress.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblAddress")).Text; TxtZip.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblZip")).Text; TxtPhone1.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblPhone1")).Text; TxtPhone2.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblPhone2")).Text; TxtEmailID.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblEmailID")).Text; TxtCustName.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblCustName")).Text; TxtCreditLimit.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblCreditLimit")).Text; TxtPrincipalName.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblPrincipalName")).Text; TxtPrincipalMobile.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblPrincipalMobile")).Text; TxtPrincipalDOB.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblPrincipalDOB")).Text; TxtKeyPersonName.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblKeyPersonName")).Text; TxtKeyPersonMobile.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblKeyPersonMobile")).Text; TxtKeyPersonDOB.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblKeyPersonDOB")).Text; TxtAdditinalDis.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblAdditinalDis")).Text; TxtVIPRemark.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblVIPRemark")).Text; TxtMedium.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblMedium")).Text; ChkIsActive.Checked = ((CheckBox)grdCustDetails.Rows[e.NewEditIndex].FindControl("chkisActive")).Checked; LblSuperzone.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblSuperZoneID")).Text; Lblzone.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblZoneID")).Text; LblAreazone.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblAreaZoneID")).Text; LblArea.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblAreaID")).Text; LblCustDetailID1.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("LblCustDetailID")).Text; TxtCustomerType.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblctype")).Text; txtcreditdays.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblcreditdays")).Text; lblrating.Text = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblcustrating")).Text; try { DDLsuperzone.SelectedValue = LblSuperzone.Text.Trim(); DDLzone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(LblSuperzone.Text), "Zone"); DDLzone.DataBind(); DDLzone.Items.Insert(0, new ListItem("--Select Zone--", "0")); DDLzone.SelectedValue = Lblzone.Text.Trim(); DDLareazone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(Lblzone.Text), "AreaZone"); DDLareazone.DataBind(); DDLareazone.Items.Insert(0, new ListItem("--Select AreaZone--", "0")); DDLareazone.SelectedValue = LblAreazone.Text.Trim(); DDLarea.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(LblAreazone.Text), "Area"); DDLarea.DataBind(); DDLarea.Items.Insert(0, new ListItem("--Select Area--", "0")); DDLarea.SelectedValue = LblArea.Text.Trim(); } catch { } ddLStates.DataSource = Destination.GetDestination(flag); ddLStates.DataBind(); ddLStates.Items.Insert(0, new ListItem("--Select State--", "0")); ddLStates.SelectedValue = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblstate1")).Text.Trim(); ddlCity.DataSource = Destination.GetDestination(Convert.ToString(ddLStates.SelectedValue)); ddlCity.DataBind(); ddlCity.Items.Insert(0, new ListItem("--Select City--", "0")); ddlCity.SelectedValue = ((Label)grdCustDetails.Rows[e.NewEditIndex].FindControl("lblCity")).Text.Trim(); DataView dv1 = new DataView(Masterofmaster.Get_MasterOfMaster_ByGroup("CustRating").Tables[0]); DdlCustRating.DataSource = dv1; DdlCustRating.DataBind(); DdlCustRating.Items.Insert(0, new ListItem("--Select Rating--", "0")); DdlCustRating.SelectedValue = lblrating.Text.Trim(); DDLCC.DataSource = CustCategory.GetCustomerCategoryMaster("adminCCM"); DDLCC.DataBind(); DDLCC.Items.Insert(0, new ListItem("--Select Category--", "0")); DDLCC.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblCMID")).Text.Trim(); DDLCSC.DataSource = CustCategory.GetCustomerCategoryMaster("adminSubCCM"); DDLCSC.DataBind(); DDLCSC.Items.Insert(0, new ListItem("--Select Sub Category--", "0")); DDLCSC.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblCMIDSUB")).Text.Trim(); } catch { } }
protected void grdEmpDetails_RowEditing(object sender, GridViewEditEventArgs e) { try { pnlEmployeeDetails.Visible = false; Panel1.Visible = true; btnSavE.Visible = false; filter.Visible = false; txtempCode.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblEmpcode")).Text; //DDLsuperzone.DataSource = SuperZone.GetSuperzonemaster(); //DDLsuperzone.DataBind(); // DDLsuperzone.Items.Insert(0, new ListItem("--Select SuperZone--", "0")); // DDLSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); DDLSDZone.DataBind(); DDLSDZone.Items.Insert(0, new ListItem("All", "0")); DDLstate.DataSource = Customer_cs.Get_DestinationMaster("state"); DDLstate.DataBind(); DDLstate.Items.Insert(0, new ListItem("--Select State--", "0")); // pnlEmployeeDetails.Visible = false; Panel1.Visible = true; LblEmpID.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblEID")).Text; txtFname.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblFName")).Text; txtMname.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblMiddleName")).Text; txtLname.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblLastName")).Text; Rdogender.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblGender")).Text; txtDob.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblDOB")).Text; // txtphne1.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblPhone1")).Text; txtphne2.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblPhone2")).Text; txtzipCode.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblZip")).Text; txtEmail.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblEmailID")).Text; txtAdd.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblAddress")).Text; /// DDLSDZone.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblSDZoneId")).Text; DDLsuperzone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLSDZone.SelectedValue.ToString()), "SuperZone1"); DDLsuperzone.DataBind(); DDLsuperzone.Items.Insert(0, new ListItem("All", "0")); /// // DDLsuperzone.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblSuperZoneID")).Text; DDLzone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLsuperzone.SelectedValue.ToString()), "Zone"); DDLzone.DataBind(); DDLzone.Items.Insert(0, new ListItem("All", "0")); DDLzone.Enabled = true; //// DDLzone.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblZoneID")).Text; DDLareazone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLzone.SelectedValue.ToString()), "AreaZone"); DDLareazone.DataBind(); DDLareazone.Items.Insert(0, new ListItem("All", "0")); DDLareazone.Enabled = true; //// DDLareazone.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblAreaZoneID")).Text; Chkarea.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(DDLareazone.SelectedValue.ToString()), "Area"); Chkarea.DataBind(); Chkarea.Items.Insert(0, new ListItem("All", "0")); Chkarea.Enabled = true; selectArea(Convert.ToInt32(LblEmpID.Text.Trim())); //Chkarea.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblAreaID")).Text; txtDepCode.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblDeptId")).Text; string JoinDate = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblJoinDate")).Text; string ResignationDate = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblResignationDate")).Text; Chekacv.Checked = ((CheckBox)grdEmpDetails.Rows[e.NewEditIndex].FindControl("chkisActive")).Checked; txtjoin.Text = JoinDate; txtResign.Text = ResignationDate; DDLstate.SelectedValue = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblState")).Text; DDLcity.DataSource = Customer_cs.Get_DestinationMaster(DDLstate.SelectedValue.ToString()); DDLcity.DataBind(); DDLcity.Items.Insert(0, new ListItem("--Select City--", "0")); DDLcity.Enabled = true; DDLcity.Focus(); // DDLcity.DataSource = Customer_cs.Get_DestinationMaster(DDLstate.SelectedValue.ToString()); // DDLcity.DataBind(); // DDLcity.Items.Insert(0, new ListItem("--Select City--", "0")); // DDLcity.Enabled = true; DDLcity.SelectedItem.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblCity")).Text; imgprof.ImageUrl = "../Images/profileimg/" + ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblphoto")).Text; lblImage.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("lblphoto")).Text; ddlqulification.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblQualification")).Text; fillQualification(); DDlDesignation.Text = ((Label)grdEmpDetails.Rows[e.NewEditIndex].FindControl("LblDesignation")).Text; fillDesignation(); } catch { } }
protected void Page_Load(object sender, EventArgs e) { if (Session["ChetanaCompanyName"] != null) { if (Session["FY"] != null) { strChetanaCompanyName = Session["ChetanaCompanyName"].ToString(); strFY = Session["FY"].ToString(); } else { Session.Clear(); } //Response.Write(strFY); } if (!Page.IsPostBack) { if (ddlCustmore.SelectedValue.ToLower().ToString() == "0" || ddlCustmore.SelectedValue.ToLower().ToString() == "") { } else { // ShowDetails(); } ddlSDZone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "SDZone"); ddlSDZone.DataBind(); ddlSDZone.Focus(); DDLSuperZone.Items.Clear(); // ddlSDZone.Items.Insert(0, new ListItem("-Select Super Duper Zone-", "0")); DDLSuperZone.Items.Insert(0, new ListItem("-Select Super Zone-", "0")); pnlzone.Visible = true; pnlcustomer.Visible = false; // DDLSuperZone.SelectedIndex = 0; //DDLZone.SelectedIndex = 0; ddlCustmore.SelectedIndex = 0; CustomerReportView.ReportSource = null; txtcustomer.Text = ""; lblCustName.Text = ""; DDLSuperZone.Focus(); DDLZone.Items.Insert(0, new ListItem("-Select Zone-", "0")); ddlCustmore.Items.Insert(0, new ListItem("-Select Customer-", "0")); setddl(Session["zoneLevel"].ToString(), Session["zoneId"].ToString()); } if (IsPostBack) { if (rdbselect.SelectedValue == "Customer") { // if (txtcustomer.Text.ToString().Trim() != "") // { // if (txtFrom.Text.Trim() != "" && txtTo.Text.Trim() != "") // { // ShowDetails(); // } // } //else // { // if (ddlDetails.SelectedValue == "details") // { // MessageBox("Select Customer"); // } // else // { if (txtFrom.Text != "" && txtTo.Text != "") { ShowDetails(); } // } // } } else { if (DDLSuperZone.SelectedValue != "0") { if (txtFrom.Text.Trim() != "" && txtTo.Text.Trim() != "") { ShowDetails(); } } else { // MessageBox("Select SuperZone"); } } } }
public void Bind_DDL_Supplier() { ddlSupplier.DataSource = Masters.Get_AreaZone_Zone_SuperZone(0, "Supplier"); ddlSupplier.DataBind(); ddlSupplier.Items.Insert(0, new ListItem("-Select Supplier-", "0")); }
public void FillForm() { try { //DDLareazone.Enabled = true; //DDLarea.Enabled = true; //DDLzone.Enabled = true; //btnSave.Visible = true; PnlAdd.Visible = true; //PnlAdd.Enabled= false; //btnSave.Text = "Update"; //btnSave.Enabled = true; LblCustId.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCustID")).Text; TxtCustCode.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCustCode")).Text; TxtShortForm.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblShortForm")).Text; TxtFamilyCode.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblFamilyCode")).Text; TxtAddress.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblAddress")).Text; TxtZip.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblZip")).Text; TxtPhone1.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblPhone1")).Text; TxtPhone2.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblPhone2")).Text; TxtEmailID.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblEmailID")).Text; TxtCustName.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCustName")).Text; TxtCreditLimit.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCreditLimit")).Text; TxtPrincipalName.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblPrincipalName")).Text; TxtPrincipalMobile.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblPrincipalMobile")).Text; TxtPrincipalDOB.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblPrincipalDOB")).Text; TxtKeyPersonName.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblKeyPersonName")).Text; TxtKeyPersonMobile.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblKeyPersonMobile")).Text; TxtKeyPersonDOB.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblKeyPersonDOB")).Text; TxtAdditinalDis.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblAdditinalDis")).Text; TxtVIPRemark.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblVIPRemark")).Text; TxtMedium.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblMedium")).Text; ChkIsActive.Checked = ((CheckBox)grdCustDetails.Rows[0].FindControl("chkisActive")).Checked; LblSuperzone.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblSuperZoneID")).Text; Lblzone.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblZoneID")).Text; LblAreazone.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblAreaZoneID")).Text; LblArea.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblAreaID")).Text; LblCustDetailID1.Text = ((Label)grdCustDetails.Rows[0].FindControl("LblCustDetailID")).Text; TxtCustomerType.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblctype")).Text; txtcreditdays.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblcreditdays")).Text; lblrating.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblcustrating")).Text; txtSchAdditionalDis.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblSchAdditionalDis")).Text; txtTODValue1.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODValue1")).Text; txtTODValue2.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODValue2")).Text; txtTODValue3.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODValue3")).Text; txtTODDisc1.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODDisc1")).Text; txtTODDisc2.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODDisc2")).Text; txtTODDisc3.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblTODDisc3")).Text; TxtblkRemark.Text = ((Label)grdCustDetails.Rows[0].FindControl("Lblblkremark")).Text; TxtblkDate.Text = ((Label)grdCustDetails.Rows[0].FindControl("Lblblkdate")).Text; txtUpperlimit.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCUL")).Text; txtLowerlimit.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblCLL")).Text; chk_splitdc.Checked = ((CheckBox)grdCustDetails.Rows[0].FindControl("chk_isSplit")).Checked; //ReadMe Comment(Zaid Ansari) Any Problem SBUCode Dropdown Bind Find This Method GetSBUCode() lblSBUCodeNone.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblSUBCode")).Text == "" ? "0" : lblSBUCodeNone.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblSUBCode")).Text; txtPANNo.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblPan")).Text; txtGst.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblGst")).Text; txtStateCode.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblStateCode")).Text; try { //ReadMe Comment(Zaid Ansari)(Dropdown Bind) Super Zone ,State,City,Category Any Problem Find This Method fillzones() ddlSbucode.DataSource = Masterofmaster.Get_MasterOfMaster_ByGroup_ForDropdown("SBU", "DropDown"); ddlSbucode.DataBind(); ddlSbucode.Items.Insert(0, new ListItem("--Seelct SBU Code--", "0")); ddlSbucode.SelectedValue = lblSBUCodeNone.Text; DDLsuperzone.SelectedValue = LblSuperzone.Text; DDLzone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(LblSuperzone.Text), "Zone"); DDLzone.DataBind(); DDLzone.Items.Insert(0, new ListItem("--Select Zone--", "0")); DDLzone.SelectedValue = Lblzone.Text.Trim(); DDLareazone.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(Lblzone.Text), "AreaZone"); DDLareazone.DataBind(); DDLareazone.Items.Insert(0, new ListItem("--Select AreaZone--", "0")); DDLareazone.SelectedValue = LblAreazone.Text.Trim(); DDLarea.DataSource = Masters.Get_AreaZone_Zone_SuperZone(Convert.ToInt32(LblAreazone.Text), "Area"); DDLarea.DataBind(); DDLarea.Items.Insert(0, new ListItem("--Select Area--", "0")); DDLarea.SelectedValue = LblArea.Text.Trim(); } catch { } ddLStates.DataSource = Destination.GetDestination(flag); ddLStates.DataBind(); ddLStates.Items.Insert(0, new ListItem("--Select State--", "0")); ddLStates.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblstate1")).Text.Trim(); ddlCity.DataSource = Destination.GetDestination(Convert.ToString(ddLStates.SelectedValue)); ddlCity.DataBind(); ddlCity.Items.Insert(0, new ListItem("--Select City--", "0")); ddlCity.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblCity")).Text.Trim(); DataView dv1 = new DataView(Masterofmaster.Get_MasterOfMaster_ByGroup("CustRating").Tables[0]); DdlCustRating.DataSource = dv1; DdlCustRating.DataBind(); DdlCustRating.Items.Insert(0, new ListItem("--Select Rating--", "0")); DdlCustRating.SelectedValue = lblrating.Text.Trim(); ChkBlacklist.Checked = ((CheckBox)grdCustDetails.Rows[0].FindControl("ChKBList")).Checked; //lblboardid.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblboardid")).Text; //DDLBoard.DataSource = Masterofmaster.Get_MasterOfMaster_ByGroup("Board").Tables[0]; //DDLBoard.DataBind(); //DDLBoard.Items.Insert(0, new ListItem("--Select Board--", "0")); //DDLBoard.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblboardid")).Text; txtassociation.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblassociation")).Text; txtcgp.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblcgp")).Text; txtbuisiness.Text = ((Label)grdCustDetails.Rows[0].FindControl("lblbuisiness")).Text; DDLCC.DataSource = CustCategory.GetCustomerCategoryMaster(flag); DDLCC.DataBind(); DDLCC.Items.Insert(0, new ListItem("--Select Category--", "0")); DDLCC.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblCMID")).Text.Trim(); DDLCSC.DataSource = CustCategory.GetCustomerCategoryMaster(Convert.ToString(DDLCC.SelectedValue)); DDLCSC.DataBind(); DDLCSC.Items.Insert(0, new ListItem("--Select City--", "0")); DDLCSC.SelectedValue = ((Label)grdCustDetails.Rows[0].FindControl("lblCMIDSUB")).Text.Trim(); } catch (Exception ex) { } }