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

Reorder column

2 Answers 60 Views
GridView
This is a migrated thread and some comments may be shown as answers.
ofer alper
Top achievements
Rank 1
ofer alper asked on 11 Jan 2010, 12:38 PM
Hi,

I need to have control over the reordering of columns. More specific, in case the user reorder column, i need to reorder another column in order to keep the symmetry.

I tried to use ColumnReordered event but i have 2 problems with this approach:

1) I am having infinite loop, because i also have to user grid.ReorderColumns  (and then i get the event again)

2) in the  ColumnReordered  event i don't have the original index of the column before the reordering. I need it in order to know which other column should i reorder.

Thanks,

Ofer

2 Answers, 1 is accepted

Sort by
0
Stefan Dobrev
Telerik team
answered on 14 Jan 2010, 07:44 AM
Hi ofer alper,

Please find my answers in order:
  1. You will have to have some kind of flag in your application that will prevent you from infinite loop. When you start your reordering you will raise the flag and when you are finished you will pull it down. Also you will not do any reordering when the flag is raised.
  2. We are already considering adding a new event - ColumnReordering on RadGridView for the next version of the control. It will allow you to achieve your requirements.

Thank you for your feedback. I have updated your Telerik points.

Greetings,
Stefan Dobrev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Tsvyatko
Telerik team
answered on 27 Jan 2010, 11:13 AM
Hi ofer alper,

In order to provide more flexibility on reordering columns, we have provided a new event - ColumnReordering on RadGridView. It will be available in our next internal build (29/01).

Best wishes,
Tsvyatko
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
GridView
Asked by
ofer alper
Top achievements
Rank 1
Answers by
Stefan Dobrev
Telerik team
Tsvyatko
Telerik team
Share this question
or