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

Drag and Drop with TreeViewDragCue and Listbox

8 Answers 144 Views
DragAndDrop
This is a migrated thread and some comments may be shown as answers.
Audrey
Top achievements
Rank 1
Audrey asked on 14 Jan 2011, 10:06 AM
Hi,

I used a Listbox and I want to drag and drop items into it to reorder them. I used RadDragAndDropManager. I have seen in your samples (http://demos.telerik.com/silverlight/#DragAndDrop/TreeToGrid) that there is a dragcue with the TreeViewDragCue to see where the selected item will be dropped. But when I use the TreeViewDragCue in a Listbox the behavior is different. Is it possible to have the same with a Listbox ?

Audrey

8 Answers, 1 is accepted

Sort by
0
Tsvyatko
Telerik team
answered on 14 Jan 2011, 11:19 AM
Hello Audrey,

The drop indicator in the example of the treeview. In order to create similar experience to the listbox you can follow this help article - http://www.telerik.com/help/silverlight/raddraganddrop-between-listboxes-with-user-feedback.html

Kind regards,
Tsvyatko
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Audrey
Top achievements
Rank 1
answered on 14 Jan 2011, 01:59 PM
Thank you.
But I want to use a WrapPanel into my Listbox as a ItemsPanelTemplate. In this case the DragCue stay on the left and it don't follow the drag action. Do you have an idea to solve my problem ?
0
Accepted
Tsvyatko
Telerik team
answered on 17 Jan 2011, 10:34 AM
Hi Audrey,

I have prepared project that demonstrate how to create feedback when the ItemsPanel is wrapPanel. Please have a look at the attachment and let me know if you have any further questions.

Best wishes,
Tsvyatko
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Audrey
Top achievements
Rank 1
answered on 17 Jan 2011, 01:54 PM
Thank you very much.
It's exactly what I wanted but if I want to select multiple items, only one item is sent to the playload property. How can I do to manage drag and drop for multiple items ?
0
Tsvyatko
Telerik team
answered on 19 Jan 2011, 01:45 PM
Hello Audrey,

I can suggest one additional option in addition to the one, I have suggested in the other thread. You can inherit Microsoft listbox and it mode similar to DragElementAction of our RadGridView. Thus it will have the ability to suppress clearing selection when clicking on selected item.

Please check the attached project. If you select multiple items from the first ListBox and click on the selected item the selection will not be cleared.

Kind regards,
Tsvyatko
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
Audrey
Top achievements
Rank 1
answered on 24 Jan 2011, 09:41 AM
Thank you for your help !
0
chandrasekhar
Top achievements
Rank 1
answered on 15 Mar 2011, 02:47 PM
problem with de-selection.
select all / some values from top list box. and try to de-select the item which you already selected.

Please help me with solution.
0
Tsvyatko
Telerik team
answered on 15 Mar 2011, 04:57 PM
Hi chandrasekhar,

 I have updated the sample project so, that MouseUp deselects items if necessary. Please, check the attachment as reference.

Greetings,
Tsvyatko
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
Tags
DragAndDrop
Asked by
Audrey
Top achievements
Rank 1
Answers by
Tsvyatko
Telerik team
Audrey
Top achievements
Rank 1
chandrasekhar
Top achievements
Rank 1
Share this question
or