Redigera

Dela via


DragDrop.GiveFeedback Attached Event

Definition

Occurs continuously while a drag-and-drop operation is in progress, and enables the drag source to give feedback to the user.

see AddGiveFeedbackHandler, and RemoveGiveFeedbackHandler
see AddGiveFeedbackHandler, and RemoveGiveFeedbackHandler
see AddGiveFeedbackHandler, and RemoveGiveFeedbackHandler

Remarks

The GiveFeedback event is raised continuously while the drag source is being dragged. This event is paired with the DragOver event on the drop target. The default handler for this event checks whether the drag source is over a valid drop target. If it is, it checks the allowed effects of the drop target. It then gives feedback to the end user regarding the allowed drop effects. This is typically done by changing the mouse cursor to a no-drop, copy, or move cursor. You should only handle this event if you need to use custom cursors to provide feedback to the user. If you handle this event, you must mark it as handled to prevent the default behavior from overriding your handler.

Caution

This event is raised continuously during the drag-and-drop operation. Therefore, you should avoid resource-intensive tasks in the event handler. For example, use a cached cursor instead of creating a new cursor each time the GiveFeedback event is raised.

Routed Event Information

Identifier field GiveFeedbackEvent
Routing strategy Bubbling
Delegate GiveFeedbackEventHandler

The corresponding tunneling event is PreviewGiveFeedback.

Applies to

See also