如何在gridview中编辑和删除数据? [英] How to edit and delete data in a gridview?
本文介绍了如何在gridview中编辑和删除数据?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个带有两个数据绑定字段和两个命令字段(用于编辑和删除)的gridview.
我无法编辑或删除任何行.
请发送任何代码.
解决方案
这是示例代码...只需遍历...您是否正在寻找类似的东西?
< asp:TemplateField HeaderText =" 编辑" > < ItemTemplate < asp:LinkButton ID =" runat =" 文本 =" CommandName =" > < /asp:LinkButton > < /ItemTemplate > < EditItemTemplate >
以在ASP.NET 2.0中可编辑GridView开头 [ ^ ].没有人会向您发送任何直接代码.在互联网上搜索更多文章.
http://geekswithblogs.net/dotNETvinz/archive/2009/02/22/gridview-insert-edit-update-and-delete--the-ado.net-way.aspx [ http://www.dotnetfunda.com/articles/article29.aspx [ http://www.aspdotnet-suresh.com/2011/02/how-to-inserteditupdate-and-delete-data.html [ http://论坛. asp.net/t/1667924.aspx/1?Edit+and+delete+Data+in+gridview+using+Access+Data+Source [ 解决方案
This is an example code...Just go through it...Are you looking for something like this?
<asp:TemplateField HeaderText ="Edit" > <ItemTemplate > <asp:LinkButton ID ="lnk1" runat ="server" Text ="Edit" CommandName ="edit"> </asp:LinkButton> </ItemTemplate> <EditItemTemplate>
Start with Editable GridView in ASP.NET 2.0[^]. No one will send you any direct code. Search on the internet for more articles.
Hi,
http://geekswithblogs.net/dotNETvinz/archive/2009/02/22/gridview-insert-edit-update-and-delete--the-ado.net-way.aspx[^]
http://www.dotnetfunda.com/articles/article29.aspx[^]
http://www.aspdotnet-suresh.com/2011/02/how-to-inserteditupdate-and-delete-data.html[^]
http://forums.asp.net/t/1667924.aspx/1?Edit+and+delete+Data+in+gridview+using+Access+Data+Source[^]
这篇关于如何在gridview中编辑和删除数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文