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

Getting customized display


I would like to know if it is possible to get the display settings after a user change columns visibility, order or columns width?

With the columnDrop method, I can have the moved column but not its order in the column list. I also tried the getColumns method but the order is from the first generation of the grid and doesn't take the changed order by the user.

I need to save these custom settings so I need to retrieve all data that users modify (visibility, order, and width).

Is there a way to do that?


1 Reply

PS Pavithra Subramaniyam Syncfusion Team June 17, 2019 08:38 AM UTC

Hi thibault, 

Thanks for contacting Syncfusion support. 

We have analyzed your requirement. We suggest you to use the “getColumns()” method of Grid to get entire Grid column’s settings after you perform reordering or set visibility or set width for the columns. This method will return the proper updated settings for the Grid’s columns. As the reorder action will not get completed in the “columnDrop” event, the column settings were not updated properly in this handler. So we suggest you to call the “getColumns()” method in the timeout of the columnDrop event to get the updated setting in that event. 
                var obj = document.getElementById("Grid").ej2_instances[0] 
If you dynamically change the width for the column, then you need to call the “refershColumns()” method to have the changes applied to Grid column’s width. 
Documentations :  

Please get back to us if you need further assistance. 
Pavithra S. 

Live Chat Icon For mobile
Up arrow icon