Asp:ButtonColumn remove button not work
i've found out that only LinkButton works not PushButton, can anyone explain it?
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Tanvir HudaRank #4,089 · 366 reputationPosted Jan 13, 2004, 8:50 PM EST
pjwingold5 reputationPosted Jan 19, 2004, 2:15 PM EST
private void InitializeComponent()
{
this.add.Click += new System.EventHandler(this.Add_Click);
this.OrderList.DeleteCommand += new System.Web.UI.WebControls.DataGridCommandEventHandler(this.OrderList_Delete);
this.checkout.Click += new System.EventHandler(this.checkout_Click);
this.Load += new System.EventHandler(this.Page_Load);
}
private void OrderList_Delete(Object sender, DataGridCommandEventArgs e)
{
cart = (ShoppingCart) Session["Cart"];
if (cart.Orders.Count > 0)
{
cart.Remove(e.Item.Cells[0].Text);
LoadData();
}
if (cart.Orders.Count == 0)
{
msgLabel.Text = "Nothing in cart";
checkout.Visible = false;
OrderList.Visible = false;
}
}if i change to push button, it will not work any more