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

Drag and drop Radlistbox and bindingsource

2 Answers 102 Views
ComboBox and ListBox (obsolete as of Q2 2010)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
IT Development
Top achievements
Rank 1
IT Development asked on 05 Jun 2009, 09:26 AM
Hello,

I have a RadListbox and a couple of textboxes bound to a bindingsource with as datasource a generic list with objects.   When the selection in the listbox is changed the text in the textboxes also reflect the current selected object. All works fine there

The listbox supports dragging and dropping of items (RadItemDragDropManager).   But when the order of the items is changed these changes are not reflected in the bindingsource and textboxes.

any suggestion how i can realize that ?

kind regards,

Tim van Rooijen

2 Answers, 1 is accepted

Sort by
0
Accepted
Nikolay
Telerik team
answered on 11 Jun 2009, 07:04 AM

Hello Tim,

Thank you for contacting us.

I am attaching a modified version of the RadItemDragDropManager. In this version, the manager is not actually removing and inserting the RadListBoxItems, but it is reordering the items in the data structure (in the RefreshItemsAfterDragDrop method) - for the purposes of the example this data structure is a BindingList. Since the RadListBox is bound to the BindingList, when the order of the items in the BindingList is changed, this reflects on the RadListBoxItems as well. Feel free to modify the RadItemDragDropManager further according to your specific needs.

I hope this helps. If you have additional questions, feel free to contact me.

Sincerely yours,

Nikolay
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
IT Development
Top achievements
Rank 1
answered on 11 Jun 2009, 08:15 AM

Hello Nikolay,

 

Thanks for your reply.

Just tested id and it Works really nice.

Really appreciate the effort

 

Greetings Tim


Tags
ComboBox and ListBox (obsolete as of Q2 2010)
Asked by
IT Development
Top achievements
Rank 1
Answers by
Nikolay
Telerik team
IT Development
Top achievements
Rank 1
Share this question
or