3

我有一个包含列的gridview:

名字 | 姓氏 | 添加

<asp:GridView ID="gv1" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False"
            DataKeyNames="AuthorID" DataSourceID="SqlDataSource1" OnRowCommand="gv1_RowCommand">
            <Columns>
                <asp:BoundField DataField="FirstName" HeaderText="FirstName" SortExpression="FirstName" />
                <asp:BoundField DataField="LastName" HeaderText="LastName" SortExpression="LastName" />
                <asp:ButtonField ButtonType="Button" Text="Add" />
            </Columns>
        </asp:GridView>

单击添加按钮时,将此行复制到第二个网格视图并从原始网格视图中隐藏/删除该行。这该怎么做?

4

1 回答 1

3

http://forums.asp.net/p/1297473/2522734.aspx

http://aspdotnetcodebook.blogspot.com/2009/04/how-to-move-selected-record-from-one.html

看看这些链接。这会帮助你

于 2013-03-07T05:49:38.317 回答