Hi!
I'm using the following code to manage drag and drop from a listbox to the ScheduleView:
In the OnDragQuery() method I change the snapping behavior of the ScheduleView because I want different behavior when dragging appointments within the ScheduleView and when dragging items from the ListBox into the ScheduleView.
In the OnDropQuery() method I reset the behavior back to default again.
The problem occurs if the user cancels the drag by for example pressing the Escape-key.
I don't know how to catch that event so that I can reset the behavior there also.
I have noticed that the DragStatus enum used in DragDropQueryEventArgs contains several statuses that I would like to handle.
But I don't understand how to reach them. The OnDragQuery() method only fires upon drag and the RadDragAndDropManager does not have a suitable method like for example AddDragCancelHandler.
Regards,
Håkan
I'm using the following code to manage drag and drop from a listbox to the ScheduleView:
RadDragAndDropManager.AddDragQueryHandler(MyList,
new
EventHandler<DragDropQueryEventArgs>(
this
.OnDragQuery));
RadDragAndDropManager.AddDropQueryHandler(MyList,
new
EventHandler<DragDropQueryEventArgs>(
this
.OnDropQuery));
In the OnDragQuery() method I change the snapping behavior of the ScheduleView because I want different behavior when dragging appointments within the ScheduleView and when dragging items from the ListBox into the ScheduleView.
In the OnDropQuery() method I reset the behavior back to default again.
The problem occurs if the user cancels the drag by for example pressing the Escape-key.
I don't know how to catch that event so that I can reset the behavior there also.
I have noticed that the DragStatus enum used in DragDropQueryEventArgs contains several statuses that I would like to handle.
But I don't understand how to reach them. The OnDragQuery() method only fires upon drag and the RadDragAndDropManager does not have a suitable method like for example AddDragCancelHandler.
Regards,
Håkan