protected void GridView_Rooms_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     if (e.Exception != null)
     {
         Label_StatusMsg.Text = e.Exception.Message;
     }
 }
Пример #2
0
 protected void GridView5_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     this.GridView1.DataBind();
     this.GridView2.DataBind();
     this.GridView3.DataBind();
     this.GridView4.DataBind();
 }
 protected void GridView2_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     this.ClientDocuments.DataBind();
     this.EngineerDocs.DataBind();
     this.SolicitorDocs.DataBind();
     this.CarhireDocs.DataBind();
 }
Пример #4
0
 protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     sclist2 = (List<ShoppingItem>)Session["sclist"];
     GridView1.DataSource = sclist2;
     GridView1.DataBind();
     GridView1.EditIndex = -1;
 }
Пример #5
0
 protected void LocationGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     ApplyFilter();
     if (e.Exception == null)
     {
         ShowMessageBox("Location successfully updated");
     }
 }
 protected void StudentSectionRowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     //            ApplyFilter();
     //            if (e.Exception == null)
     {
         ShowMessageBox("Section successfully updated");
     }
 }
 protected void SectionInstructorGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     ApplyFilter();
     if (e.Exception == null)
     {
         ShowMessageBox("Section Instructor successfully updated");
     }
 }
Пример #8
0
 protected void GvFeedback_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
     if (e.Exception != null)
     {
         this.lblError.Text = "A database error has occured.  Message: " + e.Exception.Message;
         e.ExceptionHandled = true;
         e.KeepInEditMode   = true;
     }
     else if (e.AffectedRows == 0)
     {
         this.lblError.Text = "Another user may have updated that category. Please try again";
     }
 }
 protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     if (e.Exception != null && e.Exception.InnerException != null)
     {
         if (e.Exception.InnerException is System.Data.DBConcurrencyException)
         {
             //hata burada yakalanıp handle edilir eğer DBConcurrencyException hatası aldıysak
             //o zaman conflict olmuş demektir. Hata mesajını gösteren label'ın visible'ını açalım.
             UpdateConflictMessage.Visible = true;
             e.ExceptionHandled = true;
         }
     }
 }
 protected void DepartmentGridView_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
     successid.Visible = true;
     if (e.AffectedRows > 0)
     {
         successid.Text = "Department  With ID=\""
                          + e.Keys[0].ToString() + "\" is Successfully Updated";
     }
     else
     {
         successid.Text = "Department  With ID=\""
                          + e.Keys[0].ToString() + "\" is not deleted Due To an Error";
     }
 }
Пример #11
0
 protected void GridView3_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
     if (e.AffectedRows < 1)
     {
         e.KeepInEditMode = true;
         savedShipLabel.Text = "Row is not updated.";
         savedShipLabel.ForeColor = System.Drawing.Color.Red;
     }
     else
     {
         savedShipLabel.Text = "Row updated successfully.";
         savedShipLabel.ForeColor = System.Drawing.Color.Navy;
     }
 }
        protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
        {
            apto = Session["Ap"].ToString();
            bloco = Session["Bloco"].ToString();
            oAPmodel.apartamento = Convert.ToInt32(apto);
            oAPmodel.bloco = Convert.ToInt32(bloco);

            foreach (var item in oProprietario.BuscaMoradorAdmin(oAPmodel))
            {
                lblApto.Text = item.ap.apartamento.ToString();
                lblBloco.Text = "0" + item.ap.bloco.ToString();
                lblNome.Text = item.proprietario1;
                lblEmail.Text = item.email;
            }
        }
        protected void NurseGridView_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
        {
            Label1.Visible = true;

            if (e.AffectedRows > 0)
            {
                Label1.Text      = "Nurse With ID =\"" + e.Keys[0] + "is Successfully Updated";
                Label1.ForeColor = Color.Green;
            }
            else
            {
                Label1.Text      = "Nurse With ID =\"" + e.Keys[0].ToString() + "\"is not Updated Due To an Error";
                Label1.ForeColor = Color.Red;
            }
        }
 protected void grdProducts_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     if (e.Exception != null)
     {
         lblServerError.Visible = true;
         lblServerError.Text = "A database error occured. Message: " + e.Exception.Message;
         e.ExceptionHandled = true;
         e.KeepInEditMode = true;
     }
     else if (e.AffectedRows == 0)
     {
         lblServerError.Visible = true;
         lblServerError.Text = "Another user may have updated this entry already";
     }
         
 }
 protected void GridView1_RowUpdated(
 Object sender, GridViewUpdatedEventArgs e)
 {
     if (e.Exception != null)
     {
     lblError.Text = "A database error has occurred.<br /><br />" +
         e.Exception.Message;
     if (e.Exception.InnerException != null)
         lblError.Text += "<br />Message: "
             + e.Exception.InnerException.Message;
     e.ExceptionHandled = true;
     e.KeepInEditMode = true;
     }
     else if (e.AffectedRows == 0)
     lblError.Text = "Another user may have updated that category."
         + "<br />Please try again.";
 }
        protected void GridViewItemsList_RowUpdated(object sender, GridViewUpdatedEventArgs e)
        {
            if (e.Exception == null )
            {

                string keyName = "ID";
                int id = (int)e.Keys[keyName];
                int statusid = int.Parse(e.NewValues["Status"].ToString());
                string email = e.NewValues["Email"].ToString();
                string Serial = e.NewValues["Serial"].ToString();
                Debug.WriteLine(string.Format("ID={0}, statusid={1}, email:{2}, Serial:{3}", id, statusid, email, Serial));
                try
                {
                    SendEmail(id, statusid, email, Serial);
                }
                catch (Exception ex)
                {
                    Debug.WriteLine("SendEmail:" + ex.ToString());
                }
            }
        }
        protected void grdProdutos_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
        {
            var grdProdutos = grdProdutosComposicao.Parent;

            while (grdProdutos.ID != "grdProdutos")
            {
                grdProdutos = grdProdutos.Parent;
            }


            var dtvPedido = grdProdutosComposicao.Parent;

            while (dtvPedido.ID != "mainTable")
            {
                dtvPedido = dtvPedido.Parent;
            }
            dtvPedido = dtvPedido.FindControl("dtvPedido");

            ((DetailsView)dtvPedido).DataBind();
            ((GridView)grdProdutos).DataBind();
        }
		protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
		{
			var gridView = (GridView)sender;
			if (e.AffectedRows > 0)
			{
				var name = (string)e.NewValues["LicenseName"];
				var email = (string)e.NewValues["LicenseEmail"];
				var productName = (string)e.OldValues["ProductName"];
				string licenseKey;
				Helper.GetProductAndLicenseKey(name, email, productName, out licenseKey);
				var license = tubeCentric.Payments.License.GetByKey(email, productName);
				if (license != null)
				{
					license.GeneratedLicenseKey = licenseKey;
					using (var model = PaymentsDataModel.NewContext())
					{
						model.Attach(license);
						model.SaveDataModel(model.Licenses);
					}
					gridView.DataBind();
				}
			}
		}
Пример #19
0
        protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
        {
            if (((DropDownList)GridView1.Rows[GridView1.EditIndex].Cells[3].FindControl("DropDownList1")).SelectedIndex == 0)
            {
                if(!(toggle % 2 == 0))
                {

                    //run default page of plugin
                    int index = GridView1.EditIndex;
                    GridViewRow row = GridView1.Rows[index];
                    TextBox lblfilename = (TextBox)row.Cells[2].FindControl("TextBox1");
                    string filename = lblfilename.Text;
                    var path = "../Plugins/" + filename.Replace(".", "_") + "/Default.aspx";
                    Response.Redirect(path);

                }
            }
            else
            {
                if (!(toggle % 2 == 0))
                {
                    //deactivate plugin
                    int index = GridView1.EditIndex;
                    GridViewRow row = GridView1.Rows[index];
                    TextBox lblfilename = (TextBox)row.Cells[2].FindControl("TextBox1");
                    string filename = lblfilename.Text;
                    string folder = filename.Replace(".", "_");//passed to uninstall page
                    string pageurl = "../Plugins/" + filename.Replace(".", "_") + "/Pages/home.aspx";
                    string path = "~/Plugins/" + filename.Replace(".", "_") + "/Deactivate.aspx";//?dir="+folder+"&task=deactivate&pageurl="+pageurl;
                    HttpCookie cookie = new HttpCookie("plugin");
                    cookie.Values.Add("folder", folder);
                    cookie.Values.Add("pageurl", pageurl);
                    Response.Cookies.Add(cookie);
                    Response.Redirect(string.Format(path));
                }
            }
        }
Пример #20
0
		protected void permisosGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
		{
			if (e.Exception != null)
			{
				ScriptManager.RegisterStartupScript(this.Parent.Page, GetType(), "Message", Funciones.TextoScript(e.Exception.Message), false);
				e.ExceptionHandled = true;
			}
		}
 /// <summary>
 /// Enables the buttons when the gridview edit is updated
 /// </summary>
 protected void gvMenuItems_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     btnAddMenuItem.Enabled = true;
     ddlChooseItem.Enabled = true;
     ddlAddGetCategory.Enabled = true;
     btnEnterPurchase.Enabled = true;
     btnManageCategories.Enabled = true;
     btnManageMenuItems.Enabled = true;
     btnIngredients.Enabled = true;
 }
Пример #22
0
		public static void grid_RowUpdated (object sender, GridViewUpdatedEventArgs e)
		{
			Hashtable local = WebTest.CurrentTest.UserData as Hashtable;
			if (local != null)
				local.Add (local.Count, "RowUpdated");
		}
Пример #23
0
 protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     FormView1.DataBind();
 }
Пример #24
0
		protected virtual void OnRowUpdated (GridViewUpdatedEventArgs e)
		{
			if (Events != null) {
				GridViewUpdatedEventHandler eh = (GridViewUpdatedEventHandler) Events [RowUpdatedEvent];
				if (eh != null) eh (this, e);
			}
		}
 protected void GridViewProperty_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     this.FillPropertyGrid(false);
     upnlEditSection.Update();
 }
Пример #26
0
 protected void Gridview1_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
 }
Пример #27
0
 protected void grdMedia_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
 }
Пример #28
0
 protected void ProjectListGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
 }
Пример #29
0
 protected void GridView1_RowUpdated1(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
     //   Response.Redirect("AdminPage.aspx");
 }
Пример #30
0
 protected void GridView1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     Session["hasUpdated"] = true;            
 }
Пример #31
0
 protected void OnGridViewRowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     DetailsView1.DataBind();
 }
Пример #32
0
 protected void Unnamed1_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
 }
Пример #33
0
 protected void grdProdutos_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
 {
     BindControls();
 }
Пример #34
0
		bool UpdateCallback (int recordsAffected, Exception exception)
		{
			GridViewUpdatedEventArgs dargs = new GridViewUpdatedEventArgs (recordsAffected, exception, currentEditRowKeys, currentEditOldValues, currentEditNewValues);
			OnRowUpdated (dargs);

			if (!dargs.KeepInEditMode)				
				EndRowEdit ();

			return dargs.ExceptionHandled;
		}
Пример #35
0
 protected void ExamGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
     if (e.Exception == null)
     {
         ShowMessageBox("Exam is successfully updated");
     }
 }
Пример #36
0
		protected void impuestosGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
		{
			if (e.Exception != null)
			{
				ScriptManager.RegisterStartupScript(this.Parent.Page, GetType(), "Message", "<SCRIPT LANGUAGE='javascript'>alert('" + e.Exception.Message.ToString().Replace("'", "") + "');</SCRIPT>", false);
				e.ExceptionHandled = true;
			}
		}
Пример #37
0
		public void DoOnRowUpdated (GridViewUpdatedEventArgs e)
		{
			base.OnRowUpdated (e);
		}
 protected void grdClientes_RowUpdated(object sender, GridViewUpdatedEventArgs e)
 {
 }
 protected virtual new void OnRowUpdated(GridViewUpdatedEventArgs e)
 {
 }