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

Column drag and drop

5 Answers 242 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Haroon
Top achievements
Rank 1
Haroon asked on 24 May 2007, 12:29 PM
Hi,
 I am using winforms Q1 2007 RadGridView and new to telerik controls, what i am trying to do is disable column drag and drop of grid columns, I have already tried MasterGridViewTemplate.AllowDragToGroup = False but with little success, it stops drag and drop to group panel, but if i drop it outside the child form of the application the column disappears, i just want disable drag and drop of grid column, please help.

Regards
Haroon

5 Answers, 1 is accepted

Sort by
0
Kiril
Telerik team
answered on 24 May 2007, 01:47 PM
Hi Haroon,

Thank you for bringing this question up. There are a variety of scenarios in which columns can be resized, reordered, removed, and so on, and we need to provide more clarity on how to handle them with the properties we've provided.

To disable column removing and reordering you need to set the following properties:

this.radGridView1.MasterGridViewTemplate.AllowColumnRemove = false;  
this.radGridView1.MasterGridViewTemplate.AllowColumnReorder = false;  
this.radGridView1.MasterGridViewTemplate.AllowColumnChooser = false

You might also need to disable the column chooser (the third row in the above code snippet), as you won't be needing it in case you're disabling column removing.

If you have any other questions, please don't hesitate to contact us.
 
Regards,
Kiril
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Haroon
Top achievements
Rank 1
answered on 24 May 2007, 02:55 PM
Hi Kiril,
 Thanks for the help, I have tried the proposed solution, but i get compilation error for:

Line: dgvValues.MasterGridViewTemplate.AllowColumnRemove

Error: Error 1 'AllowColumnRemove' is not a member of 'Telerik.WinControls.UI.GridViewTemplate'. 

Regards
Haroon
0
Kiril
Telerik team
answered on 24 May 2007, 03:39 PM
Hello Haroon,

Sorry for the confusion.

Are you using the Service Pack 1 version of the controls? Could you tell me the version numbers of the RadControls for Winforms libraries?


Best wishes,
Kiril
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Haroon
Top achievements
Rank 1
answered on 24 May 2007, 10:20 PM
I have looked into the DLL version it is 3.0.0.0

Regards
Haroon
0
Haroon
Top achievements
Rank 1
answered on 25 May 2007, 02:01 AM
Thanks for the help, the proposed solution works, after i upgraded to SP1

Regards
Haroon
Tags
GridView
Asked by
Haroon
Top achievements
Rank 1
Answers by
Kiril
Telerik team
Haroon
Top achievements
Rank 1
Share this question
or