开发者

Bind DataGrid using ajax

开发者 https://www.devze.com 2023-03-31 02:23 出处:网络
Is it possible to set the datasource of a datagrid view using ajax?My objective is to bind a开发者_Go百科 datagrid on clicking a hyperlink(in the same page). Please help.You should use LinkButton Inst

Is it possible to set the datasource of a datagrid view using ajax? My objective is to bind a开发者_Go百科 datagrid on clicking a hyperlink(in the same page). Please help.


You should use LinkButton Instead

protected void LinkButton1_Click(object sender, EventArgs e)
{
    // set DataSource here .....
}

  <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
        <ContentTemplate>
            <%--  GridView--%>
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="LinkButton1" EventName="Click" />
        </Triggers>
    </asp:UpdatePanel>
0

精彩评论

暂无评论...
验证码 换一张
取 消