protected void ProfilesGrid_RowDeleted(object sender, GridViewDeletedEventArgs e) { if (e.Exception == null) { LinkButton UndoDel = new LinkButton(); this.roundedStat.Style["display"] = "block"; this.lblStatus.Text = "Removed " + e.Values["FirstName"] + " " + e.Values["LastName"] + " click to "; UndoDel.Text = "Undo"; UndoDel.CommandName = "Undelete"; UndoDel.CausesValidation = false; UndoDel.CommandArgument = e.Keys["RegistrationID"].ToString(); UndoDel.Command += new CommandEventHandler(UndoDel_Command); this.plchStatusControls.Controls.Add(UndoDel); this.ClientScript.RegisterStartupScript(this.GetType(), "HighlightMess", " Effect.Pulsate('round',1,0.7);", true); } } protected void UndoDel_Command(object sender, CommandEventArgs e) { if (e.CommandName.CompareTo("Undelete") == 0) { string SQL = "UPDATE Registration SET Deleted = 0 WHERE RegistrationID = " + e.CommandArgument; Util.DoCmd(SQL); this.ProfilesGrid.DataBind(); this.HideForm(sender, (EventArgs)e); } }So, it looks like the button is supposed to be added in run-time with the event handler.