使用Asp.net Gridview的Datatable插件

我在asp.net页面中使用了asp.net gridview控件。 我想使用JQUERY datatable插件进行分页。 以下是我的gridview设计,

        <asp:Label ID="lblSat" runat="server" TabIndex="1" Text=''>     <asp:Label ID="lblSun" runat="server" TabIndex="2" Text=''>     <asp:Label ID="lblMon" runat="server" TabIndex="3" Text=''>     <asp:Label ID="lblTue" runat="server" TabIndex="4" Text=''>     <asp:Label ID="lblWed" runat="server" TabIndex="5" Text=''>     <asp:Label ID="lblThu" runat="server" TabIndex="6" Text=''>     <asp:Label ID="lblFri" runat="server" TabIndex="7" Text=''>       <%-- 
--%> <input type="hidden" id="hdnTaskDetailIds" value='' runat="server" /> <%----%> <%----%> <%-- --%> <%--
--%> <%--
--%>

我使用下面的代码来应用分页

    $(function () { $('#cphBody_gvTaskDtl').prepend($("").append($(this).find("tr:first"))).dataTable({ "aaSorting": [] }); });  

问题是分页没有得到重视因为我得到错误无法读取未定义的属性’mData’当我在运行时从浏览器检查Gridview是我发现的html,

 ---- 

我能够看到两次创建thead。 可能这是创造问题。 如何从theggridview中删除空的thead

在此先感谢Sangeetha

试试这个

 $('#cphBody_gvTaskDtl').dataTable({ "aaSorting": [] });