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

Manual drag start

5 Answers 69 Views
DragAndDrop
This is a migrated thread and some comments may be shown as answers.
Flemming Rosenbrandt
Top achievements
Rank 1
Flemming Rosenbrandt asked on 21 Mar 2014, 09:21 AM
I am trying to start a drag manually using DragDropManager.DoDragDrop – but do not have any success.

Do you have a working example?

/Flemming Rosenbrandt

5 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 24 Mar 2014, 11:41 AM
Hello Flemming,

I'm not sure if I understand correctly the requirements, however in order to start drag drop operation there should be a mouse interaction
with the desired element. Firstly you will need to set the attached telerik:DragDropManager.AllowDrag property of the element in XAML and then to add DragInitialize handler in the code.

As for the DoDragDrop method - it comes from the framework itself and you don't need to use it as it is already implemented in the methods of the DragDropManager (you can check the Events section of the DragDropManager online help documentation).

Hope this helps. If you have any further questions let us know.

Regards,
Kalin
Telerik
 

Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.

 
0
Flemming Rosenbrandt
Top achievements
Rank 1
answered on 24 Mar 2014, 11:52 AM
I have normal drag drop working fine – but in some scenarios I want to start a drag without
mouse interaction.

I thought that this was what the DoDragDrop method was for?

/Flemming Rosenbrandt

0
Kalin
Telerik team
answered on 25 Mar 2014, 12:20 PM
Hello Flemming,

The DoDragDrop method is used in special scenarios, for example if you need to start the drag operation with some delay while keeping the mouse button pressed. However in order to be able to start a drag operation you will need mouse or touch interaction anyway. Could you please share some more detailed information about the exact requirements of your scenario and issues you are facing so we can provide you with an example solution?

I'm looking forward to hearing from you.

Regards,
Kalin
Telerik
 

Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.

 
0
Flemming Rosenbrandt
Top achievements
Rank 1
answered on 26 Mar 2014, 07:54 AM
I have a listbox with draggable graphic items in it. The items can be dropped on a design surface. It works fine. But for novice user I want them to be able to select an item – and then click an insert button. At this point I want to start a drag manually – so that the item is attached to the mouse and ready for a drop.

/Flemming Rosenbrandt

0
Kalin
Telerik team
answered on 27 Mar 2014, 03:16 PM
Hi Flemming,

You can achieve the desired, but the user should keep the mouse button pressed in order to continue the drag operation. We have created a sample project which demonstrates the exact approach - you will need to select an item in the first ListBox, press the button and while keeping the mouse left button down to start dragging the attached item.

Hope this will help you to achieve the requirements.

Regards,
Kalin
Telerik
 

Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.

 
Tags
DragAndDrop
Asked by
Flemming Rosenbrandt
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Flemming Rosenbrandt
Top achievements
Rank 1
Share this question
or