Click or drag to resize

DragDropServer.StartDrag Method

X#
Notify the GUI that a drag-and-drop operation has started.

Namespace:  VO
Assembly:  VOGUIClasses (in VOGUIClasses.dll) Version: 2.21
Syntax
 VIRTUAL METHOD StartDrag(
	acFilesToDrag
) AS USUAL CLIPPER
Request Example View Source

Parameters

acFilesToDrag (Optional)
Type: Usual
An array of file names to drag.

Return Value

Type: Usual
TRUE if the drop was successful; otherwise, FALSE (for example, if the user dropped the files on a non-drag-and-drop client).
Remarks
This method is called when the user starts the drag operation, usually by dragging the mouse. DragDropServer:StartDrag() is modal; once it is called, control is only returned to the program when the user has dropped the files.
Examples
The following example demonstrates how to use the DragDropServer:StartDrag() method:
X#
 1CLASS MyChildWindow INHERIT ChildAppWindow
 2HIDDEN aDragList AS ARRAY
 3METHOD Init(oOwner) CLASS MyChildAppWindow
 4SUPER:Init(oOwner)
 5EnableDragDropServer(TRUE)            // Make Window
 6// a DragDropServer
 7METHOD MouseDrag(oEvent) CLASS MyChildWindow
 8LOCAL ListLength AS INT
 9LOCAL lResult     AS LOGIC
10ListLength := ALen(aDragList)
11// aDragList is already filled with list of file names
12IF ListLength > 0         // if there are files to drag
13lResult := SELF:DragDropServer:StartDrag(aDragList)
14ENDIF
See Also