Sort persistence & Search gridview arrays

Posted on 2009-02-18
Medium Priority
Last Modified: 2012-05-06
I have an asp.net web page written in C# that displays data in a gridview from a text file. The page is built using an array of objects to display the fields. I enabled paging (a text file can hold several hundred records) and I have it sorting on several of the fields. However, once I move to the next page it loses the sort. I need the page to hold the sort when the user moves back and forth between pages. I cannot seem to get it to work. I also need to be able to search the records. I am not sure how to search the array then display the correct records. I am still learning .net and C#, and have never worked with arrays before this. Any help/samples would be appreciated. Thanks.
Question by:dodgerfan
1 Comment
LVL 27

Accepted Solution

Sammy Ageil earned 1500 total points
ID: 23686953

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …
Suggested Courses

839 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