protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) { txbABE_Cat.Text = DropDownList1.SelectedValue.ToString(); DropDownList2.Items.Clear(); DropDownList2.Items.Add(new ListItem("Κατηγορία ...", "0")); ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); if (TextBox128.Text == "0") { GridView4.Visible = false; GridView8.Visible = false; } else { GridView4.Visible = true; GridView8.Visible = true; } if (DropDownList1.SelectedValue == "4") { DropDownList111.Enabled = true; } else { DropDownList111.Enabled = false; DropDownList111.SelectedIndex = 0; } }
protected void Page_Load(object sender, EventArgs e) { Page.MaintainScrollPositionOnPostBack = true; if (TextBox124.Text.Length == 0) { TextBox124.Text = DateTime.Today.ToString("dd/MM/yyyy"); TextBox151.Text = DateTime.Today.ToString("dd/MM/yyyy"); } TextBox126.Text = User.Identity.Name; TextBox128.Text = FINANCIAL_MANAGEMENT.App_Code.xrisi.Fetch_Isotimia().ToString(); TextBox133.Text = (string)Session["ID_Pers_Check"]; calEx2.StartDate = Convert.ToDateTime(DateTime.Today.ToString("dd/MM/yyyy")); TextBox12.Text = DateTime.Parse(TextBox124.Text).Year.ToString(); if (DropDownList4.SelectedValue == "0") { DropDownList4.SelectedValue = RoundUp(DateTime.Parse(DateTime.Now.ToString(DateTime.Now.ToString("yyyy-MM-dd HH:mm"))), TimeSpan.FromMinutes(15)).ToString("HH:mm"); DropDownList5.SelectedValue = RoundUp(DateTime.Parse(DateTime.Now.ToString(DateTime.Now.ToString("yyyy-MM-dd HH:mm"))), TimeSpan.FromMinutes(15)).AddMinutes(30).ToString("HH:mm"); } xrisi(); if (DropDownList1.SelectedValue == "7") { Panel2.Visible = true; CheckBox1.Visible = true; DropDownList7.Visible = true; } else { Panel2.Visible = false; CheckBox1.Visible = false; DropDownList7.Visible = false; } TextBox158.Text = "0"; // epistrofes diavatiriwn -0 tipota, 1 epistrofi xrimatwn, 2 simpsifismos. if (TextBox138.Text.Length == 0 && (string)Session["ID_Pers_NEWPERS"] != "XXX") { new_pers(); } if ((string)Session["ID_Pers_NEWPERS"] == "XXX") { DropDownList6.Visible = true; } else { DropDownList6.Visible = false; } ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); }
protected void DropDownList2_SelectedIndexChanged(object sender, EventArgs e) { // if ((string)Session["Edit_YN"] == "0") // { // GridView12.DataSourceID = "Dikaiologitika_From_DDL"; // Dikaiologitika_From_DDL.DataBind(); // } if (DropDownList2.SelectedValue == "7" || DropDownList2.SelectedValue == "12" || DropDownList2.SelectedValue == "14" || DropDownList2.SelectedValue == "17" || DropDownList2.SelectedValue == "19") { CheckBox2.Visible = true; } else { CheckBox2.Visible = false; CheckBox2.Checked = false; } txbABE_Sub.Text = DropDownList2.SelectedValue.ToString(); ABE_Category_Revers.DataBind(); GridView9.DataBind(); if (DropDownList2.SelectedValue != "0") { string DD2_index = DropDownList2.SelectedValue; DropDownList1.SelectedValue = GridView9.Rows[0].Cells[0].Text; ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); DropDownList2.SelectedValue = DD2_index; } else { DropDownList1_SelectedIndexChanged(null, null); } ABE_Cost.DataBind(); ABE_Cost_LC.DataBind(); if (DropDownList1.SelectedValue == "4") { DropDownList111.Enabled = true; } else { DropDownList111.Enabled = false; DropDownList111.SelectedIndex = 0; } }
protected void DropDownList2_SelectedIndexChanged(object sender, EventArgs e) { if (DropDownList2.SelectedValue != "0") { ABE_Category_Revers.DataBind(); GridView9.DataBind(); string DD2_index = DropDownList2.SelectedValue; DropDownList1.SelectedValue = GridView9.Rows[0].Cells[0].Text; ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); DropDownList2.SelectedValue = DD2_index; } txbABE_Cat.Text = DropDownList1.SelectedValue.ToString(); txbABE_Sub.Text = DropDownList2.SelectedValue.ToString(); Dikaiolog.DataBind(); }
protected void DropDownList2_SelectedIndexChanged(object sender, EventArgs e) { if (DropDownList1.SelectedValue == "7") { Panel2.Visible = true; CheckBox1.Visible = true; DropDownList7.Visible = true; } else { Panel2.Visible = false; CheckBox1.Visible = false; DropDownList7.Visible = false; } if (DropDownList2.SelectedValue != "0") { ABE_Category_Revers.DataBind(); GridView9.DataBind(); string DD2_index = DropDownList2.SelectedValue; DropDownList1.SelectedValue = GridView9.Rows[0].Cells[0].Text; ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); DropDownList2.SelectedValue = DD2_index; } if (DropDownList2.SelectedValue == "7" || DropDownList2.SelectedValue == "12" || DropDownList2.SelectedValue == "14" || DropDownList2.SelectedValue == "17" || DropDownList2.SelectedValue == "19") { CheckBox2.Visible = true; } else { CheckBox2.Visible = false; CheckBox2.Checked = false; } txbABE_Sub.Text = DropDownList2.SelectedValue.ToString(); Dikaiologitika.DataBind(); GridView12.DataBind(); }
protected void DropDownList2_SelectedIndexChanged(object sender, EventArgs e) { ABE_Category_Revers.DataBind(); GridView9.DataBind(); string DD2_index = DropDownList2.SelectedValue; DropDownList1.SelectedValue = GridView9.Rows[0].Cells[0].Text; ABE_Sub_Category.DataBind(); DropDownList2.DataBind(); DropDownList2.SelectedValue = DD2_index; // TextBox9.Text = DropDownList2.SelectedItem.Text; DropDownList101.SelectedValue = "0"; DropDownList102.SelectedValue = "0"; DropDownList103.SelectedValue = "0"; DropDownList104.SelectedValue = "0"; DropDownList105.SelectedValue = "0"; DropDownList106.SelectedValue = "0"; DropDownList107.SelectedValue = "0"; DropDownList108.SelectedValue = "0"; DropDownList109.SelectedValue = "0"; DropDownList110.SelectedValue = "0"; TextBox121.Text = "0"; TextBox133.Text = "0"; ShowDDL(); if (DropDownList1.SelectedValue == "4") { DropDownList111.Enabled = true; } else { DropDownList111.Enabled = false; DropDownList111.SelectedIndex = 0; } }