protected void Button3_Click(object sender, EventArgs e) { if (RadioButtonList2.SelectedIndex < 0) { errorDiv2.InnerText = "Please select an answer"; } else if (RadioButtonList2.SelectedIndex == 3) { score++; questionsAnswered++; Button3.Enabled = false; RadioButtonList2.Items.FindByValue("correct").Attributes.Add("class", "right"); anchor.Visible = true; anchorA.Text = "Well done! Another easy one. We've all seen Anchorman, it's just full of memorable quotes"; UpdatePanel5.Update(); UpdatePanel6.Update(); UpdatePanel12.Update(); } else { questionsAnswered++; Button3.Enabled = false; RadioButtonList2.SelectedItem.Attributes.Add("class", "wrong"); RadioButtonList2.Items.FindByValue("correct").Attributes.Add("class", "right"); anchor.Visible = true; anchorA.Text = "Wow.. I thought everyone would get this one, It's Will Ferral as Ron Burgundy in this comedy gem"; UpdatePanel5.Update(); UpdatePanel6.Update(); UpdatePanel12.Update(); } }
protected void GridView4_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Choose") { int a= me.CodyDetail(new Guid(HSFID.Text),new Guid(e.CommandArgument.ToString()),Session["UserName"].ToString()); if (a >0) { ScriptManager.RegisterStartupScript(Page, typeof (Page), "alert", "alert('复制成功!')", true); } else { ScriptManager.RegisterStartupScript(Page, typeof (Page), "alert", "alert('失败了诶...')", true); } } GridView2.DataSource = me.QueryDetail(new Guid(HSFID.Text)); GridView2.DataBind(); UpdatePanel3.Update(); Panel6.Visible = false; Panel7.Visible = false; UpdatePanel6.Update(); }
protected void Button31_Click(object sender, EventArgs e) { Label36.Text = "请选择物料"; Label37.Text = "请选择物料"; UnitCheck.Visible = false; Panel41.Visible = true; TextBox14.Text = ""; TextBox15.Text = ""; TextBox17.Text = ""; FuseText.Visible = false; DropDownList4.Visible = false; Label35.Text = "请选择工序"; Guid id = new Guid(Label3.Text); GridView3.DataSource = bom.Query_BOMDetail(id); GridView3.DataBind(); Label31.Text = "新增"; DropDownList3.Items.Clear(); Label32.Text = Label4.Text; Panel4.Visible = true; Panel31.Visible = false; Panel5.Visible = false; Panel51.Visible = false; Button39.Visible = false; UpdatePanel4.Update(); UpdatePanel5.Update(); UpdatePanel3.Update(); Panel6.Visible = false; UpdatePanel6.Update(); }
protected void Button1_Click(object sender, EventArgs e) //点击检索按钮 { string a1 = TextBox1.Text; string a2 = TextBox2.Text; string a3 = TextBox3.Text; string a4 = TextBox4.Text; DateTime a5; DateTime a6; a5 = Convert.ToDateTime(TextBox5.Text == "" ? "1/1/1753 12:00:00 AM" : TextBox5.Text); a6 = Convert.ToDateTime(TextBox6.Text == "" ? "12/31/9999 11:59:59 PM" : TextBox6.Text); string a7 = TextBox7.Text; string a8 = DropDownList1.SelectedValue; string a9 = TextBox8.Text; string a10 = TextBox9.Text; int a11 = CheckBox1.Checked ? 0 : 1; GridView1.DataSource = bom.Query_ControlledDocApp(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11); GridView1.DataBind(); Panel3.Visible = false; Panel31.Visible = false; Panel4.Visible = false; Panel41.Visible = false; Panel5.Visible = false; Panel51.Visible = false; Panel6.Visible = false; UpdatePanel6.Update(); UpdatePanel1.Update(); UpdatePanel2.Update(); UpdatePanel3.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); }
protected void GridView5_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Choose") { GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Guid id = new Guid(e.CommandArgument.ToString()); Label38.Text = id.ToString(); Label36.Text = row.Cells[1].Text; Label37.Text = row.Cells[2].Text; Panel51.Visible = false; Panel52.Visible = false; Panel53.Visible = false; UnitCheck.Visible = true; DropDownList3.Items.Clear(); SqlDataReader myReader = bom.Query_MUnit(id); while (myReader.Read()) { DropDownList3.Items.Add(new ListItem(myReader["UnitName"].ToString(), myReader["UnitID"].ToString()));//增加Item } Button39.Visible = true; Panel6.Visible = false; UpdatePanel6.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); } }
private void limpiarFormulario() { TxMensaje.Text = string.Empty; TxBusqueda.Text = string.Empty; LbAprobacion.Text = string.Empty; LbIdEntrada.Text = string.Empty; LbNombreEntrada.Text = string.Empty; LbArticuloEntrada.Text = string.Empty; LbSerieEntrada.Text = string.Empty; LbInventarioEntrada.Text = string.Empty; LbFechaEntrada.Text = string.Empty; DivEntradas.Visible = false; TxNombre.Text = string.Empty; DDLArticulo.SelectedIndex = -1; TxSerie.Text = string.Empty; TxInventario.Text = string.Empty; DDLMotivo.SelectedIndex = -1; TxObservaciones.Text = string.Empty; //DDLAutorizado.SelectedIndex = -1; UpdatePanel3.Update(); UpdatePanel1.Update(); UpdatePanel2.Update(); UpdatePanel6.Update(); }
protected void SummitReturn_Click(object sender, EventArgs e) { if (TextBox9.Text == "" || Label16.Text == "请选择供应商" || TextBox44.Text == "") { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('数量、日期未填写或退货去向未选择!')", true); } else { decimal renum = Decimal.Parse(TextBox9.Text); Guid copperid = new Guid(CopperID.Text); Guid pid = new Guid(Label20.Text); Debug.Assert(TextBox44.Text != null, "时间没填哦~亲"); DateTime backDateTime = Convert.ToDateTime(TextBox44.Text); string note = TextBox43.Text; int a = pmc.Insert_CopperReturn(renum, copperid, pid, note, Session["UserName"].ToString(), backDateTime); if (a > 0) { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('提交成功!')", true); Panel6.Visible = false; UpdatePanel6.Update(); Bind1(); Bind(3); } else { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('提交失败!')", true); Panel6.Visible = false; UpdatePanel6.Update(); } } }
protected void CloseReturn_Click(object sender, EventArgs e) { Panel5.Visible = false; UpdatePanel5.Update(); Panel6.Visible = false; UpdatePanel6.Update(); }
protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Auto") { GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Panel3.Visible = true; UpdatePanel3.Update(); Maxnum.Text = row.Cells[4].Text; PID.Text = e.CommandArgument.ToString(); } if (e.CommandName == "Details") { PID.Text = e.CommandArgument.ToString(); GridView2.DataSource = pb.Query_BillMain(new Guid(PID.Text)); GridView2.DataBind(); Panel4.Visible = true; UpdatePanel4.Update(); } if (e.CommandName == "NotBill") { PID.Text = e.CommandArgument.ToString(); Panel6.Visible = true; UpdatePanel6.Update(); GridView4.DataSource = pb.Query_PurchaseOrderDetailNotBill(new Guid(PID.Text)); GridView4.DataBind(); UpdatePanel6.Update(); } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { Panel4.Visible = false; Panel3.Visible = false; Panel5.Visible = false; Panel6.Visible = false; Panel7.Visible = false; Panel8.Visible = false; Panel9.Visible = false; Panel10.Visible = false; GridView1.DataSource = pmc.Query_Copper(); GridView1.DataBind(); UpdatePanel2.Update(); UpdatePanel3.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); UpdatePanel6.Update(); UpdatePanel7.Update(); UpdatePanel8.Update(); UpdatePanel9.Update(); UpdatePanel10.Update(); } }
protected void SearchDepartment_Click(object sender, EventArgs e) { string name = TextBox8.Text; GridView3.DataSource = dp.Query_BDOS(name); GridView3.DataBind(); UpdatePanel6.Update(); }
protected void resetchoose_Click(object sender, EventArgs e) { Label27.Text = "未选择"; depid.Text = "depid"; GridView3.Dispose(); UpdatePanel6.Update(); UpdatePanel3.Update(); }
protected void GridView6_PageIndexChanging(object sender, GridViewPageEventArgs e) { GridView6.PageIndex = e.NewPageIndex; GridView6.DataSource = RFID; GridView6.DataBind(); ChartMode(); UpdatePanel6.Update(); }
protected void ChooseDepartment_Click(object sender, EventArgs e) { Panel6.Visible = true; GridView3.DataSource = dp.Query_BDOS("%"); GridView3.DataBind(); Label27.Text = "未选择"; depid.Text = "depid"; UpdatePanel6.Update(); }
protected void NewMonthPlan_Click(object sender, EventArgs e) { Panel4.Visible = true; UpdatePanel4.Update(); Panel5.Visible = false; UpdatePanel5.Update(); Panel6.Visible = false; UpdatePanel6.Update(); }
protected void GridView4_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "swi") { pb.SwitchState(new Guid(e.CommandArgument.ToString())); GridView4.DataSource = pb.Query_PurchaseOrderDetailNotBill(new Guid(PID.Text)); GridView4.DataBind(); UpdatePanel6.Update(); } }
protected void Button33_Click(object sender, EventArgs e) { GridView4.DataSource = bom.Query_PBC(TextBox16.Text); GridView4.DataBind(); Panel51.Visible = true; Panel52.Visible = false; Panel53.Visible = false; Panel5.Visible = true; UpdatePanel5.Update(); Panel6.Visible = false; UpdatePanel6.Update(); }
protected void Button38_Click(object sender, EventArgs e) { GridView5.DataSource = bom.Query_Material(TextBox21.Text, TextBox22.Text); GridView5.DataBind(); Panel51.Visible = false; Panel5.Visible = true; Panel52.Visible = true; Panel53.Visible = false; Panel6.Visible = false; UpdatePanel5.Update(); UpdatePanel6.Update(); }
protected void GridView3_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Choose") { var row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Label27.Text = row.Cells[1].Text; depid.Text = e.CommandArgument.ToString(); Panel6.Visible = false; UpdatePanel3.Update(); UpdatePanel6.Update(); } }
private void BuscarAgencias() { lstAgencia.DataSource = (DsAgencias.DatosRow[])dtAgencias.Select("Nombre like '%" + this.txtRazonSocialBusqueda.Text + "%'", "Nombre"); lstAgencia.DataTextField = "Nombre"; lstAgencia.DataValueField = "AgenciaID"; lstAgencia.DataBind(); lstPuntoRecepcion.DataSource = dtPuntosRecepcion.Select("RazonSocial LIKE '%" + this.txtPuntoRecepcionBusquedaNombre.Text + "%'", "RazonSocial"); lstPuntoRecepcion.DataTextField = "RazonSocial"; lstPuntoRecepcion.DataValueField = "PuntoRecepcionID"; lstPuntoRecepcion.DataBind(); UpdatePanel6.Update(); UpdatePanel5.Update(); }
protected void Button21_Click(object sender, EventArgs e) { Panel31.Visible = true; Label11.Text = "新增"; Label12.Text = Label2.Text; Panel4.Visible = false; Panel41.Visible = false; Panel5.Visible = false; Panel51.Visible = false; Panel6.Visible = false; UpdatePanel6.Update(); UpdatePanel3.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); }
protected void GridView4_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Choose") { GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Guid id = new Guid(e.CommandArgument.ToString()); Label34.Text = id.ToString(); Label35.Text = row.Cells[1].Text; Panel51.Visible = false; Panel6.Visible = false; UpdatePanel6.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); } }
protected void lblPublication_Click(object sender, EventArgs e) { LinkButton lb = (LinkButton)sender; GridViewRow row = (GridViewRow)lb.NamingContainer; int index = row.RowIndex; //gets the row index selected var lblMemberId = row.FindControl("lblID") as Label; var lblProjectUnit = row.FindControl("lblProject") as Label; string id = lblProjectUnit.Text + lblMemberId.Text; GridViewProject.DataSourceID = "SqlDataSourceProject"; SqlDataSourceProject.SelectCommand = "select PublicationID,b.EntryName as TypeOfEntry,TitleWorkItem from Publication a,PublicationTypeEntry_M b where a.TypeOfEntry=b.TypeEntryId and ProjectIDlist like '%" + id + "%'"; GridViewProject.DataBind(); SqlDataSourceProject.DataBind(); UpdatePanel6.Update(); paneloutcome.Visible = true; ScriptManager.RegisterStartupScript(this, this.GetType(), "CallMyFunction", "callthis2()", true); return; }
protected void Button39_Click(object sender, EventArgs e) { GridView6.DataSource = bom.Query_Unit(TextBox23.Text); GridView6.DataBind(); Label533.Text = "请选择单位"; TextBox24.Text = ""; DefaultUnit du = new DefaultUnit(); du = bom.Query_DefaultUnitID(new Guid(Label38.Text)); Label531.Text = du.Name; Label532.Text = du.Defaultid.ToString(); Panel53.Visible = true; Panel51.Visible = false; Panel5.Visible = true; Panel52.Visible = false; Panel6.Visible = false; UpdatePanel5.Update(); UpdatePanel6.Update(); }
protected void GridView9_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Modify") { GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Guid id = new Guid(e.CommandArgument.ToString()); UnitChangeID.Text = id.ToString(); TextBox11.Text = row.Cells[2].Text; Panel51.Visible = false; Panel52.Visible = false; Panel55.Visible = true; Panel53.Visible = false; Panel6.Visible = false; UpdatePanel6.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); } }
protected void GridView1_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "History") { var row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; GridView1.SelectedIndex = row.RowIndex; HSFID.Text = e.CommandArgument.ToString(); GridView2.DataSource = hd.QueryVersion(new Guid(e.CommandArgument.ToString())); GridView2.DataBind(); Panel3.Visible = true; Panel4.Visible = false; Panel5.Visible = false; Panel6.Visible = false; Panel7.Visible = false; Panel8.Visible = false; Panel9.Visible = false; UpdatePanel2.Update(); UpdatePanel3.Update(); UpdatePanel4.Update(); UpdatePanel5.Update(); UpdatePanel6.Update(); UpdatePanel7.Update(); UpdatePanel8.Update(); UpdatePanel9.Update(); } if (e.CommandName == "Details") { var row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; GridView1.SelectedIndex = row.RowIndex; HSFID.Text = e.CommandArgument.ToString(); GridView5.DataSource = hd.QueryDetailAI(new Guid(HSFID.Text)); GridView5.DataBind(); Panel6.Visible = true; UpdatePanel2.Update(); UpdatePanel6.Update(); } }
protected void ibtnAgregarDireccionDeudor_Click(object sender, ImageClickEventArgs e) { try { proveedorUbicabilidad(); comuna(); lblUsuarioDireccion.Text = Session["variableUsuario"].ToString(); txtCalle.Text = string.Empty; txtNumero.Text = string.Empty; txtResto.Text = string.Empty; ScriptManager.RegisterStartupScript(UpdatePanel6, UpdatePanel6.GetType(), "show", "$(function () { $('#" + Panel5.ClientID + "').modal('show'); });", true); UpdatePanel6.Update(); } catch (Exception ex) { divAlerta.Visible = true; lblInfo.Text = ex.Message; } }
//Called when row selection Index changes on recommended modules in Semester 2 protected void SM2_OnSelectedIndexChanged(object sender, EventArgs e) { SelROw = null; foreach (GridViewRow row in grdSugSemester2.Rows) { if (row.RowIndex == grdSugSemester2.SelectedIndex) { row.ToolTip = string.Empty; SelROw = row; selectSM2Row(SelROw); if (grdNonSugSemester2.SelectedIndex >= 0) { grdNonSugSemester2.SelectedIndex = -1; UpdatePanel2.Update(); } UpdatePanel6.Update(); } else { row.ToolTip = "Click to select this row."; } } }
protected void Pay_Click(object sender, EventArgs e) { decimal total = 0; int a = RememberPayValues(GridView4); if (a != 0) { if (a == 1) { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('计划付款数额加当月已计划数额超过了月计划数额,该项没有保存!');", true); } if (a == -1) { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('有计划金额未填哦!');", true); } } var list = Session["PurchaseWeekPlanDetailPay"] as Dictionary <string, string[]>; if (list != null) { foreach (var item in list) { string[] ids = item.Key.Split(','); string id = ids[0]; pwp.Insert_PaymentInfo(new Guid(id), Convert.ToDecimal(item.Value[1]), Convert.ToInt32(year.Text), Convert.ToInt32(month.Text), Convert.ToInt32(week.Text), Session["UserName"].ToString(), "Test"); total += Convert.ToDecimal(item.Value[1]); } ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('付款已完成!');", true); pwp.UpdatePaymentWeekPlanState(new Guid(WeekPlanID.Text), total); Panel6.Visible = false; UpdatePanel6.Update(); Bindgrid1(); } }
protected void GridView7_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Choose") { GridViewRow row = ((LinkButton)e.CommandSource).Parent.Parent as GridViewRow; Guid fromid = new Guid(e.CommandArgument.ToString()); Guid id = new Guid(Label3.Text); string man = Session["UserName"].ToString(); int a = bom.Copybom(id, fromid, man); if (a > 0) { ScriptManager.RegisterStartupScript(Page, typeof(Page), "alert", "alert('复制成功.')", true); } Panel51.Visible = false; Panel52.Visible = false; Panel53.Visible = false; Panel6.Visible = false; UpdatePanel4.Update(); UpdatePanel5.Update(); UpdatePanel6.Update(); } }