How do I sort a GridView?
<p>ASP.NET <code>GridView</code> sorting: I want to change the sorting direction from ascending to descending when I click the column name. But by default, sorting direction always showing ascending. Am I missing any property setting to toggle sorting direction? Any help greatly appreciated. Thanks.</p>

<pre><code>protected void gridView_Sorting(object sender, GridViewSortEventArgs e)
{

    DataTable dataTable = myDataTable(strSQL);

    if (dataTable != null)
    {

        DataView dataView = new DataView(dataTable);

        dataView.Sort = e.SortExpression + " " + SortDirection(e.SortDirection);

        gridView.DataSource = dataView;

        gridView.DataBind();

     }

}
//e.SortDirection always showing ascending
</code></pre>

<p>aspx gridview column design for sorting:</p>

<pre><code>&lt;asp:BoundField DataField="CREATE_DATE" HeaderText="Create Date" SortExpression="CREATE_DATE" /&gt;
</code></pre>
