当我点击vb.net中的删除按钮时如何从gridview中删除记录?

时间:2010-12-14 15:04:27

标签: asp.net vb.net

当我点击vb.net中的删除按钮时,如何从gridview中删除记录?

1 个答案:

答案 0 :(得分:0)

Gridview有一个名为'RowDeleting'的事件,您可以使用它来处理Delete事件。 例如:

Private Sub gridview_RowDeleting(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewDeleteEventArgs) Handles gridview.RowDeleting

   '' Handle your delete here and rebind your datasource if needed

End Sub