Drag and drop not working on Windows 10


Is there a reason for Drag and drop (of files from the desktop) working without issues for all my projects so far and now all of a sudden none of them on Windows 10? I have tried everything, including with Xojo 2019r2.1, everything works perfect and as expected on the Mac but on Windows all I get is a forbidden sign :-/ … Right now I don’t know where to look at. I have restarted everything. Same. Any idea? Thanks in advance!

Stan Busk

You can’t drag and drop across security levels, if your app is running as administrator you can only drag/drop to/from administrator level apps, which won’t be your desktop.

I can’t drag and drop from nowhere actually, not only desktop.

Yeah. if your app is running as administrator and all other apps are running as “User” then you won’t be able to drag anything to your app.

Check the following setting and make sure its set to User, then re-run/build your app and try again.

Have you tried Xojo’s Example Project?
File → New Project: Examples → Desktop → DragAndDrop → ListBoxDragAndDrop
Does that one work?[quote=466781:@Stanley Roche Busk]Drag and drop (of files from the desktop)[/quote]
Note: Windows is more “picky” about how you set up the accepted “FileType(s)”.
If any File should be accepted, try: .AcceptFileDrop("????")
If you’re using a FileType (or a FileType Set / FileType Group):

it need allow your wanted file types as Jürg Otter already mentioned.


see also other Self.Accept…

Sub DropObject(obj As DragItem, action As Integer) Handles DropObject
  If obj.FolderItemAvailable Then
    label1.Value = obj.FolderItem.NativePath
    label1.Value ="?"
  End If  
End Sub