gridview sort

Posted on 2014-04-10
Medium Priority
Last Modified: 2014-04-21
My user wants gridview to be sorted along with able to remember the sort on coming back to the page, visiting any other page.
Question by:welcome 123
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 39992447
What is your question?
LVL 83

Accepted Solution

CodeCruiser earned 1000 total points
ID: 39993754
1) To enable sorting, set the AllowSorting property of the gridview to true


2) Handle the Sorting event of the gridview to get the sorting that the user has applied and store it in session


3) On page load, if the user had previously sorted the gridview, apply that sorting using the Sort method


Author Comment

by:welcome 123
ID: 40002720
looks like all is working, I would close the question t'row after testing one more thing. Thanks a lot

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Hello there! As a developer I have modified and refactored the unit tests which was written by fellow developers in the past. On the course, I have gone through various misconceptions and technical challenges when it comes to implementation. I would…
Article by: Shaun
Tiling windows is a great way to see multiple applications at once. Windows Tiler is a tool that automatically tiles open application windows as the open and close.
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
Watch the video of Kernel Migrator for SharePoint, which demonstrate the process easily of migration from SharePoint to SharePoint, OneDrive for Business & Google Drive servers, Public Folder to SharePoint, File Server to SharePoint. The tool has va…

588 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question