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

calling RadGrid ColumnMovingToLeft method dynamically through javascript

1 Answer 72 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
chaitanya
Top achievements
Rank 1
chaitanya asked on 10 Oct 2011, 07:50 AM
Hi,
Teleric Radgrid supports reordering grid columns on client side. I have a requirement like if i move a column from position m to n, then columns in m+1, m+2 should move to n+1 and n+2 positions automatically(through code).

can you please help me out how can we achieve this using the javascript methods provided.

I came to know that ColumnMovingToLeft and ColumnMovingToRight property javascript methods are invoked when we reorder a column.

Thanks in advance
Chaithanya Bhadri

1 Answer, 1 is accepted

Sort by
0
Marin
Telerik team
answered on 13 Oct 2011, 08:14 AM
Hello Chaitanya,

 Indeed you can use the OnColumnMovingToLeft and OnColumnMovingToRight client side events and there reorder the columns in the desired way using the client-side methods: reorderColumns and swapColumns. You can also do this on the server in the OnColumnsReorder event using the column's OrderIndex property as shown in this help topic.

Greetings,
Marin
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
Tags
General Discussions
Asked by
chaitanya
Top achievements
Rank 1
Answers by
Marin
Telerik team
Share this question
or