We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

GridDataControl and server-side sorting

Hi,

I'm using the GridDataControl to display records downloaded from the server. The grid is in read-only mode, so I don't need to worry about editing. I would like to intercept the sort and filter events on the columns in order to issue appropriate queries to the server which will in turn download new data.
What's the best way of doing this? How can I prevent the grid from doing a sort and just update the sort indicator for me?



1 Reply

GA Gobinath A Syncfusion Team October 18, 2013 07:29 PM UTC

Hi Filip Fracz,

 

Sorry for the delay in getting back to you.

 

We have analyzed your query and would you please confirm with us would you like to intercept the sorting/filter options while adding the data in to the data source? if this is your requirement please use following code snippet in your application or else please share more details related to this query with us as this would be helpful for us to provide a solution earlier?

 

 

Code snippet[C#]:

 

void syncgrid_Loaded(object sender, RoutedEventArgs e)

        {

            this.syncgrid.Model.View.CollectionChanged += new System.Collections.Specialized.NotifyCollectionChangedEventHandler(View_CollectionChanged);

        }

 

        void View_CollectionChanged(object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e)

        {

            this.syncgrid.AllowSort = false;

            this.syncgrid.ShowFilters = false;

        }

 

 

Please let us know if you have any queries.

 

Regards,

Gobinath A

 


Loader.
Live Chat Icon For mobile
Up arrow icon