Drag() (gb.qt4)

Static Function Drag ( Source As Control, Data As Variant [ , Format As String ] ) As Control

Starts a drag & drop operation.

  • Source is the origin of the drag.

  • Data is the data that will be dragged. It can be a String or an Image

  • Format is an optional MIME format, that you can specify only if you drag textual data.

Support for URIs

Desde 3.18

If Format is "text/uri-list", then Data must be an array of file paths that will be sent to the clipboard as an URI list.


  Dim aPaths As New String[]
  aPaths.Add(User.Home &/ "File1.txt")
  aPaths.Add(User.Home &/ "File2.txt")
  aPaths.Add(User.Home &/ "File3.txt")

  Drag(MyControl, aPaths, "text/uri-list")

See also