dlg.Drag - copy, move, link

I'm having trouble with the new dlg.Drag() added to 12.20.6.

It works fine if I just use it like dlg.Drag(myVector); but as soon as I try to add the copy move or link options it forces a move regardless how I write the line.

Eg, this line will Move files on drag with no qualifier key:
dlg.Drag(myVector, "copy,move,link");

If I change it to dlg.Drag(myVector, "*copy,move,link"); it still defaults to move.

Here's a quick test button to demonstrate.

Drag Test.dcf (2.3 KB)

Can't confirm, seems to work here. Maybe you have somewhere a dialog that didn't get closed and now interferes with new ones?

No dialogs, just the test button I've included above.

Hmmm, I thought it was ok after a reboot, but it fails again after using the button a few times.

This is definitely not working for me. Can someone else test with the button above please?

I have seen it work once, but subsequent runs failed. The button is set to dlg.Drag(myVector, "*copy,move,link"); but it defaults to move on a left click.

I think the default operation is only a suggestion. It's up to the app that you drag on to to decide which of the available operations happens, and they may override the default.

e.g. I have Opus set to always move when files are dragged to it.

1 Like

Thanks @Leo, I had not considered that the receiver would have any say in it. :slight_smile:

I also have Opus set to always move when files are dragged.