hi,
from listview I want to move a number of lines to a listbox
here' s the listview's mouse_down :
if user clicks a selected item I will call DoDragDrop otherwise just select the item
that works, but from here on nothing happens
neither lv DragLeave nor lbx DragDrop respond.
DoDragDrop obviously has some dificulty with DataFormats.Serializable and/or lv.SelectedItems.
I did the same with a string and DataFormats.Text and that was ok.
am I missing something ? any ideas ?
I am using VS10
thanks in advance
franz
from listview I want to move a number of lines to a listbox
here' s the listview's mouse_down :
private void lvLib_MouseDown(object sender, MouseEventArgs e) { ListView lv = (ListView)sender; ListViewHitTestInfo info = lv.HitTest(e.X, e.Y); if (info.Item == null) return; if (info.Item.Selected) { DragDropFormat = DataFormats.Serializable; DoDragDrop(lv.SelectedItems,DragDropEffects.Copy); } }
if user clicks a selected item I will call DoDragDrop otherwise just select the item
that works, but from here on nothing happens
neither lv DragLeave nor lbx DragDrop respond.
DoDragDrop obviously has some dificulty with DataFormats.Serializable and/or lv.SelectedItems.
I did the same with a string and DataFormats.Text and that was ok.
am I missing something ? any ideas ?
I am using VS10
thanks in advance
franz
Last edited by a moderator: