This is a migrated thread and some comments may be shown as answers.

Refreshing radgrid after getting new datasource inside of grid

1 Answer 63 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ying
Top achievements
Rank 1
Ying asked on 15 Jul 2008, 06:05 PM
Hello, I am running I am having trouble with refreshing the data inside of my grid after the data changes.  I made a separate refresh button that when clicked queries my database and returns the new set of data to the grid.  The problem is when I hit the refresh button it does not remember the filters/sorts of the original data it just returns the new data in unsorted order.  I want the sorts/filters to be maintained after I refresh the radgrid.  What is the best way to do this?  Thanks

Right now I have this


    protected void imgRefresh_Click(object sender, ImageClickEventArgs e)
   
    {



    

        // Queries the database to get any changes
        EntitySearchResult = _helper.RepopulateSearchEntityResults(UserID,                 FacilityId, Request.Cookies,                     UIConfig.GlobalConfiguration.MaxRecordsToReturn);
       
          // Renders Data to appear in rad grid
            DisplayResults();


       
       

       
        ramGrid.ResponseScripts.Add("top.HideLoading();");
       
    }

How can I keep the sorting/filtering of my original data when ir un this function?


1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 16 Jul 2008, 06:40 AM
Hi Ying,

Go through the following help article which explains how to save the runtime settings of a RadGrid.
Saving grid settings on a per user basis

Thanks
Shinu.
Tags
Grid
Asked by
Ying
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or