
Officialboss
Top achievements
Rank 1
Officialboss
asked on 21 Jul 2008, 03:34 PM
Hello,
I am exploring the Drag and Drop feature of the RadGrid. Can I drag and drop the Cell content (numeric value) of RadGrid1 to a cell in RadGrid2? Could you please direct me a sample that demonstrate this?
Thanks.
I am exploring the Drag and Drop feature of the RadGrid. Can I drag and drop the Cell content (numeric value) of RadGrid1 to a cell in RadGrid2? Could you please direct me a sample that demonstrate this?
Thanks.
6 Answers, 1 is accepted
0

Officialboss
Top achievements
Rank 1
answered on 21 Jul 2008, 05:28 PM
The cell in RadGrid where I want to drop the numeric value will have a template column with a TextBox.
0

Officialboss
Top achievements
Rank 1
answered on 22 Jul 2008, 06:08 PM
Anyone tried this in their projects?
0
Hi Howard,
With RadGrid's items drag and drop functionality, you can move only the entire griddataitems. If you want only cells to be drag and dropped you may consider implementing custom drag and drop functionality. I have attached a page with very basic implementation of the desired behavior to get you started. Please feel free to modified it to better suite your needs.
Best wishes,
Rosen
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
With RadGrid's items drag and drop functionality, you can move only the entire griddataitems. If you want only cells to be drag and dropped you may consider implementing custom drag and drop functionality. I have attached a page with very basic implementation of the desired behavior to get you started. Please feel free to modified it to better suite your needs.
Best wishes,
Rosen
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0

Officialboss
Top achievements
Rank 1
answered on 23 Jul 2008, 04:16 PM
This will certainly get me started in the right direction.
I thank you very much!!
I thank you very much!!
0

Officialboss
Top achievements
Rank 1
answered on 25 Jul 2008, 11:03 PM
Hello,
A few follow up questions from your example:
var currentElement = Telerik.Web.UI.Grid.GetCurrentElement(e);
Referring to the line above, what other elements of the Grid can I get?
I want to restrict the column of the source grid the value can be dragged from.
After dragging the value of a Cell in RadGrid1(source grid) and running a validation and a successful droping into the destination(RadGrid2) how do I disable the original value that was just dragged, to prohibit from being dragged again?
Thanks
A few follow up questions from your example:
var currentElement = Telerik.Web.UI.Grid.GetCurrentElement(e);
Referring to the line above, what other elements of the Grid can I get?
I want to restrict the column of the source grid the value can be dragged from.
After dragging the value of a Cell in RadGrid1(source grid) and running a validation and a successful droping into the destination(RadGrid2) how do I disable the original value that was just dragged, to prohibit from being dragged again?
Thanks
0
Hello Howard,
The GetCurrentElement function is use for getting the element which is the source of the raised dom event. Therefore this can be any element.
In order to restrict which columns can be dragged, you can check if the dragged cell belongs to a column with certain UniqueName.
To your last question. You can mark the cell which was dragged and then check for this mark when user tries to move it again.
I have attached a modified version of the page in order to demonstrate the above suggestions.
Greetings,
Rosen
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
The GetCurrentElement function is use for getting the element which is the source of the raised dom event. Therefore this can be any element.
In order to restrict which columns can be dragged, you can check if the dragged cell belongs to a column with certain UniqueName.
To your last question. You can mark the cell which was dragged and then check for this mark when user tries to move it again.
I have attached a modified version of the page in order to demonstrate the above suggestions.
Greetings,
Rosen
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.