Asp.net 在回发时保留表排序器顺序

Asp.net 在回发时保留表排序器顺序,asp.net,ajaxcontroltoolkit,tablesorter,rowdatabound,Asp.net,Ajaxcontroltoolkit,Tablesorter,Rowdatabound,我正在ASP.NET上使用带有Gridview的TableSorter2.0插件。我使用此代码修复了THEAD问题: if (GridView1.Rows.Count > 0) { GridView1.UseAccessibleHeader = true; GridView1.HeaderRow.TableSection = TableRowSection.TableHeader; GridView1.FooterRow.TableSection

我正在ASP.NET上使用带有Gridview的TableSorter2.0插件。我使用此代码修复了
THEAD
问题:

if (GridView1.Rows.Count > 0)
   {
      GridView1.UseAccessibleHeader = true;
      GridView1.HeaderRow.TableSection = TableRowSection.TableHeader;
      GridView1.FooterRow.TableSection = TableRowSection.TableFooter;
   }
排序行时一切都很好,但当我在单击每行时使用此代码执行
postback
时,问题就开始了

Private Sub GridView1_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GridView1.RowDataBound
        If e.Row.RowType = DataControlRowType.DataRow Then
            e.Row.Attributes("onclick") = Page.ClientScript.GetPostBackClientHyperlink(GridView1, "Select$" & e.Row.RowIndex)
        End If
End Sub
Tablesorter一直工作得很好,我可以对列进行排序,但是当我在gridview上单击一行进行回发时
我以前排序的行返回到它们的原始位置,就像第一次加载一样,并且不保留我所做的排序。为了以防万一,我还使用了一个
UpdatePanel

我有一个将当前排序保存到本地存储的,带有cookie回退功能的。遗憾的是,这个小部件无法在tablesorter的原始版本上工作